factorydriver.h

来自「这是广泛使用的通信开源项目,对于大容量,高并发的通讯要求完全能够胜任,他广泛可用」· C头文件 代码 · 共 81 行

H
81
字号

// -*- C++ -*-
// FactoryDriver.h,v 1.3 1999/06/06 01:37:39 coryan Exp

// ============================================================================
//
// = LIBRARY
//    TAO/orbsvcs/examples/CosEC/Factory
//
// = FILENAME
//    FactoryDriver.h
//
// = DESCRIPTION
//    This class implements the Factory driver.
//
// = AUTHOR
//    Pradeep Gore <pradeep@cs.wustl.edu>
//
// ============================================================================

#ifndef TAO_FACTORYDRIVER_H
#define TAO_FACTORYDRIVER_H

#include "CosEventChannelFactory_i.h"
#include "orbsvcs/Naming/Naming_Utils.h"

// @@ Pradeep: I know this is just an example, but could you talk to
//    Vishal about making this a service that could be bootstraped
//    using the -ORBInitRef mechanisms?  That way we can run this
//    stuff without the naming service running.

class FactoryDriver
{
  // = TITLE
  //   Driver class for the CosEventChannel Factory.
  // = DESCRIPTION
  //   creates a CosEventChannel Factory and registers it with the
  //   naming service.
  //
 public:
  // = Initialization and termination code.
  FactoryDriver (const char* factory = "CosEC_Factory");
  // Constructor.

  ~FactoryDriver (void);
  // Destructor.

  int start (int argc, char *argv []);
  // Start the driver.

  int stop (void);
  //Stop the driver.

 protected:
  int parse_args (int argc, char *argv []);
  // Parse the command-line arguments and set options.

  const char* factoryName_;
  // The name of the factory registered with the naming service.

  const char* child_poa_name_;
  // The name of the Child POA.

  CORBA::ORB_var orb_;
  // The ORB that we use.

  TAO_CosEventChannelFactory_i *factory_servant_;
  // The factory servant.

  PortableServer::POA_var root_poa_;
  // Reference to the root poa.

  CosEventChannelFactory::ChannelFactory_var factory_;
  // The corba object after activation.

  TAO_Naming_Client naming_client_;
  // Use a naming client.

};
#endif /*  TAO_FACTORYDRIVER_H */

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?