Examples: IBM® Rational® Software Architect Designer extensions

The IBM® Rational® Software Architect Designer extensions use the following XML namespace definition: xmlns:rsa="http://rational.software.architect". This section provides examples of Service Component extensions and Environment extensions, and shows sample WSDL and WADL fragments.

Service Component extensions

The following three extensions are child elements of the <wsdl:definitions> element or the <wadl:application> element:
  • <rsa:model_reference value="/Model1/Blank%20Package.emx"/>: Added to the Description field in the Documentation tab of the Service Component.

  • <rsa:path value="Blank Package::Package1::Component1"/>: Added to the Description field in the Documentation tab of the Service Component.

  • <rsa:rm_link value="http://www.abc.com/rm/41965"/>: Added to the External Documentation field in the Documentation tab of the Service Component.

    The following screen shot shows the editor of a WSDL Service Component in Logical View:

You can also access the value of the <rsa:rm_link> element from the Test Factory perspective by clicking Documentation in the context menu of any node under the Service Component. The following screen shot shows the context menu:

Environment extensions

The following extension is a child element of the <wsdl:service> element or the <wadl:application> element and is repeatable:
<rsa:environment>
<rsa:envname value="Travel.DBSingleNode"/>
<rsa:envlocation value="CityA/OfficeA/ServerA"/>
</rsa:environment>
This value is placed in the Description field in the Documentation tab of the environment that you select or create while adding the documents to HCL OneTest API project. Following is a sample screen shot:

A sample WSDL fragment

The following sample is a WSDL fragment:
<?xml version="1.0" encoding="utf-8"?>
	<wsdl:definitions 
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
    xmlns:rsa="http://rational.software.architect">
	<rsa:model_reference value="/Model1/Blank%20Package.emx"/>
	<rsa:path value="Blank Package::Package1::Component1"/>
	<rsa:rm_link value="http://www.abc.com/rm/41965"/>
		<wsdl:types>
		...
		<wsdl:binding name="CalculatorSoap" type="tns:CalculatorSoap">
			<soap:binding transport="http://schemas.xmlsoap.org/soap/http" />
			<wsdl:operation name="Add">
				<soap:operation soapAction="http://tempuri.org/Add" style="document" />
				<wsdl:input>
				<soap:body use="literal" />
				</wsdl:input>
				<wsdl:output>
				<soap:body use="literal" />
				</wsdl:output>
			</wsdl:operation>
			...
		</wsdl:binding>
		<wsdl:service name="Calculator">
			<rsa:environment>
				<rsa:envname value="Travel.DBSingleNode"/>
				<rsa:envlocation value="CityA/OfficeA/ServerA"/>
			</rsa:environment>
			<rsa:environment>
				<rsa:envname value="Travel.DBDualNode"/>
				<rsa:envlocation value="CityC/OfficeC/ServerC"/>
			</rsa:environment>
			<wsdl:port name="CalculatorSoap" binding="tns:CalculatorSoap">
			<soap:address location="http://www.dneonline.com/calculator.asmx" />
			</wsdl:port>
			<wsdl:port name="CalculatorSoap12" binding="tns:CalculatorSoap12">
			<soap12:address location="http://www.dneonline.com/calculator.asmx" />
			</wsdl:port>
		</wsdl:service>
	</wsdl:definitions>

A sample WADL fragment

The following sample is a WADL fragment:
<wadl:application 
      xmlns:wadl="http://wadl.dev.java.net/2009/02"   
      xmlns:rsa="http://rational.software.architect">
	<rsa:model_reference value="/Model1/Blank%20Package.emx"/>
	<rsa:path value="Blank Package::Package1::Component1"/>
	<rsa:rm_link value="http://www.abc.com/rm/41965"/>
	<rsa:environment>
      <rsa:envname name="dualNodeTopology"/>
      <rsa:envlocation location="Location1/Location2/Node"/>
	</rsa:environment>
	<rsa:environment>
		<rsa:envname name="singleNodeTopology"/>
		<rsa:envlocation location="LocationA/Node"/>
	</rsa:environment>
	<wadl:resources base="/*">
		<wadl:resource path="/resourceclass">
		<wadl:method id="PUTOperation" name="PUT"/>
		<wadl:method id="GETOperation" name="GET"/>
		</wadl:resource>
	</wadl:resources>
</wadl:application>