ViewVC Help
View File | Revision Log | Show Annotations | Revision Graph | Root Listing
root/i-scream/projects/cms/source/server/uk/org/iscream/cms/server/clientinterface/CorbaClientListenerServant.java
(Generate patch)

Comparing projects/cms/source/server/uk/org/iscream/cms/server/clientinterface/CorbaClientListenerServant.java (file contents):
Revision 1.3 by tdb, Sat Feb 3 04:47:49 2001 UTC vs.
Revision 1.4 by tdb, Mon Feb 5 00:58:46 2001 UTC

# Line 9 | Line 9 | import uk.ac.ukc.iscream.client.*;
9  
10   /**
11   * This class, a servant, listens for incoming connections from CORBA based
12 < * clients. Once it receives a connection it creates and assigns a CorbaHandler
13 < * object to it. The CorbaHandler will then handle all requests on behalf of the
12 > * clients. Once it receives a connection it creates and assigns a CorbaControlHandler
13 > * object to it. The CorbaControlHandler will then handle all requests on behalf of the
14   * client, and will send the client data.
15   *
16   * @author  $Author$
# Line 44 | Line 44 | class CorbaClientListenerServant extends CorbaClientLi
44      /**
45       * Allows a CORBA client to connect to the server.
46       *
47     * @param name the name of the connecting client.
47       * @param client a reference to the "servant" part of the connecting client.
48 <     * @return a CorbaHandler reference.
48 >     * @return a CorbaControlHandler reference.
49       */
50 <    public CorbaHandler connect(String name, Client client) {
51 <        CorbaHandlerServant chServant = new CorbaHandlerServant(_packetSorter, name, client);
53 <        CorbaHandlerPOATie chPOATie = new CorbaHandlerPOATie(chServant);
50 >    public CorbaControlHandler connect(Client client) {
51 >        CorbaControlHandlerServant cchServant = new CorbaControlHandlerServant(_packetSorter, client);
52          org.omg.CORBA.Object objRef;
53          try {
54 <            objRef = _refman.getRootPOA().servant_to_reference(chPOATie);
54 >            objRef = _refman.getRootPOA().servant_to_reference(cchServant);
55          } catch (Exception e) {
56              objRef = null;
57 <            _logger.write(toString(), Logger.ERROR, "Error creating CorbaHandler: "+e);
57 >            _logger.write(toString(), Logger.ERROR, "Error creating CorbaControlHandler: "+e);
58          }
59 <        CorbaHandler corbaHandler = CorbaHandlerHelper.narrow(objRef);
62 <        ((Thread) corbaHandler).start();
59 >        CorbaControlHandler corbaHandler = CorbaControlHandlerHelper.narrow(objRef);
60          return corbaHandler;
61      }
62      

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines