HelloWorldControl.jcx Sample

This topic inludes the source code for the HelloWorldControl.jcx Sample.

Sample Location

This sample is located in the following directory in your WebLogic Workshop installation:

BEA_HOME/weblogic81/samples/workshop/SamplesApp/WebApp/tagSamples/netui_databinding/callControl/

Sample Source Code


001 package tagSamples.netui_databinding.callControl;
002 
003 /**
004  * @jc:location http-url="HelloWorld.jws" jms-url="HelloWorld.jws"
005  * @jc:wsdl file="#HelloWorldWsdl"
006  * @editor-info:link autogen-style="java" source="HelloWorld.jws" autogen="true"
007  */
008 public interface HelloWorldControl extends com.bea.control.ControlExtension, com.bea.control.ServiceControl
009 {
010     
011     public java.lang.String hello ();
012 
013     static final long serialVersionUID = 1L;
014 }
015 
016 /** @common:define name="HelloWorldWsdl" value::
017     <?xml version="1.0" encoding="utf-8"?>
018     <definitions xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:conv="http://www.openuri.org/2002/04/soap/conversation/" xmlns:cw="http://www.openuri.org/2002/04/wsdl/conversation/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:jms="http://www.openuri.org/2002/04/wsdl/jms/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:s0="http://www.openuri.org/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" targetNamespace="http://www.openuri.org/">
019       <types>
020         <s:schema elementFormDefault="qualified" targetNamespace="http://www.openuri.org/" xmlns:s="http://www.w3.org/2001/XMLSchema">
021           <s:element name="hello">
022             <s:complexType>
023               <s:sequence/>
024             </s:complexType>
025           </s:element>
026           <s:element name="helloResponse">
027             <s:complexType>
028               <s:sequence>
029                 <s:element name="helloResult" type="s:string" minOccurs="0"/>
030               </s:sequence>
031             </s:complexType>
032           </s:element>
033           <s:element name="string" nillable="true" type="s:string"/>
034         </s:schema>
035     
036       </types>
037       <message name="helloSoapIn">
038         <part name="parameters" element="s0:hello"/>
039       </message>
040       <message name="helloSoapOut">
041         <part name="parameters" element="s0:helloResponse"/>
042       </message>
043       <message name="helloHttpGetIn"/>
044       <message name="helloHttpGetOut">
045         <part name="Body" element="s0:string"/>
046       </message>
047       <message name="helloHttpPostIn"/>
048       <message name="helloHttpPostOut">
049         <part name="Body" element="s0:string"/>
050       </message>
051       <portType name="HelloWorldSoap">
052         <operation name="hello">
053           <input message="s0:helloSoapIn"/>
054           <output message="s0:helloSoapOut"/>
055         </operation>
056       </portType>
057       <portType name="HelloWorldHttpGet">
058         <operation name="hello">
059           <input message="s0:helloHttpGetIn"/>
060           <output message="s0:helloHttpGetOut"/>
061         </operation>
062       </portType>
063       <portType name="HelloWorldHttpPost">
064         <operation name="hello">
065           <input message="s0:helloHttpPostIn"/>
066           <output message="s0:helloHttpPostOut"/>
067         </operation>
068       </portType>
069       <binding name="HelloWorldSoap" type="s0:HelloWorldSoap">
070         <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"/>
071         <operation name="hello">
072           <soap:operation soapAction="http://www.openuri.org/hello" style="document"/>
073           <input>
074             <soap:body use="literal"/>
075           </input>
076           <output>
077             <soap:body use="literal"/>
078           </output>
079         </operation>
080       </binding>
081       <binding name="HelloWorldHttpGet" type="s0:HelloWorldHttpGet">
082         <http:binding verb="GET"/>
083         <operation name="hello">
084           <http:operation location="/hello"/>
085           <input>
086             <http:urlEncoded/>
087           </input>
088           <output>
089             <mime:mimeXml part="Body"/>
090           </output>
091         </operation>
092       </binding>
093       <binding name="HelloWorldHttpPost" type="s0:HelloWorldHttpPost">
094         <http:binding verb="POST"/>
095         <operation name="hello">
096           <http:operation location="/hello"/>
097           <input>
098             <mime:content type="application/x-www-form-urlencoded"/>
099           </input>
100           <output>
101             <mime:mimeXml part="Body"/>
102           </output>
103         </operation>
104       </binding>
105       <service name="HelloWorld">
106         <port name="HelloWorldSoap" binding="s0:HelloWorldSoap">
107           <soap:address location="http://localhost:7001/tagSamples/netui_databinding/callControl/HelloWorld.jws"/>
108         </port>
109         <port name="HelloWorldHttpGet" binding="s0:HelloWorldHttpGet">
110           <http:address location="http://localhost:7001/tagSamples/netui_databinding/callControl/HelloWorld.jws"/>
111         </port>
112         <port name="HelloWorldHttpPost" binding="s0:HelloWorldHttpPost">
113           <http:address location="http://localhost:7001/tagSamples/netui_databinding/callControl/HelloWorld.jws"/>
114         </port>
115       </service>
116     </definitions>
117  * ::
118  */