axis-java-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ru...@apache.org
Subject cvs commit: xml-axis/java/src/org/apache/axis/client ServiceClient.java
Date Mon, 11 Jun 2001 17:33:35 GMT
rubys       01/06/11 10:33:35

  Modified:    java/src/org/apache/axis/client ServiceClient.java
  Log:
  Minor cleanup - I hate it comments get out of synch with the code!
  
  I'll take a look at getting doLocal working again, this time as a
  transport.
  
  Revision  Changes    Path
  1.7       +5 -39     xml-axis/java/src/org/apache/axis/client/ServiceClient.java
  
  Index: ServiceClient.java
  ===================================================================
  RCS file: /home/cvs/xml-axis/java/src/org/apache/axis/client/ServiceClient.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- ServiceClient.java	2001/06/11 12:30:50	1.6
  +++ ServiceClient.java	2001/06/11 17:33:34	1.7
  @@ -116,7 +116,8 @@
        * Set it up yourself!
        */
       public ServiceClient () {
  -        this.setupEngine();
  +        engine = new AxisClient();
  +        engine.init();
           msgContext = new MessageContext(engine);
       }
       
  @@ -124,11 +125,9 @@
        * Construct a ServiceClient with the given Transport.
        */
       public ServiceClient (Transport transport) {
  +        this();
           this.transport = transport;
           
  -        this.setupEngine();
  -        msgContext = new MessageContext(engine);
  -        
           // set up the message context with the transport
           try {
               transport.init(engine);
  @@ -148,26 +147,6 @@
       }
       
       /**
  -     * Set up the engine as appropriate for client / server.
  -     */
  -    private void setupEngine () {
  -        // For testing - skip HTTP layer
  -        if (engine != null) {
  -            return;
  -        }
  -        
  -        if ( doLocal ) {
  -            engine = new org.apache.axis.server.AxisServer();
  -            engine.init();
  -        } else {
  -            engine = new AxisClient();
  -            engine.init();
  -        }
  -    }
  -    
  -    
  -    
  -    /**
        * Set property; pass through to MessageContext.
        * This works because the constants defined in Transport and its
        * subclasses are synonyms for MessageContext constants.
  @@ -348,19 +327,6 @@
           // local (if null) or pre-existing transport (if !null)
           Message              reqMsg = new Message( reqEnv, "SOAPEnvelope" );
           
  -        /* Ok, this might seem strange, but here it is...                    */
  -        /* Create a new AxisClient Engine and init it.  This will load any   */
  -        /* registries that *might* be there.  We set the target service to   */
  -        /* the service so that if it is registered here on the client        */
  -        /* we'll find it's request/response chains and invoke them.  Next we */
  -        /* check to see if there is any ServiceRegistry at all, or if there  */
  -        /* is one, check to see if a chain called HTTP.input is there.  If   */
  -        /* not then we need to default to just the simple HTTPDispatchHandler*/
  -        /* to call the server.                                               */
  -        /* The hard part about the client is that we can't assume *any*      */
  -        /* configuration has happened at all so hard-coded defaults are      */
  -        /* required.                                                         */
  -        /*********************************************************************/
           if ( Debug.getDebugLevel() > 0  ) {
               DebugHeader  header = new DebugHeader(Debug.getDebugLevel());
               header.setActor( Constants.URI_NEXT_ACTOR );
  @@ -377,9 +343,9 @@
               throw fault ;
           }
           
  -        Message       resMsg = msgContext.getResponseMessage();
  +        // Message       resMsg = msgContext.getResponseMessage();
           //SOAPEnvelope  resEnv = (SOAPEnvelope) resMsg.getAs( "SOAPEnvelope" );
  -        msgContext.setResponseMessage(resMsg);
  +        // msgContext.setResponseMessage(resMsg);
           /*
            SOAPBody      resBody = null; //resEnv.getFirstBody();
           
  
  
  

Mime
View raw message