summaryrefslogtreecommitdiff
path: root/TAO/tests/DLL_ORB/Test_Client_Module.h
blob: bd6496920685ea169dffa39f4a3b8cfc136f49b2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
// -*- C++ -*-

//=============================================================================
/**
 * @file Test_Client_Module.h
 *
 * $Id$
 *
 * @author Ossama Othman <ossama@uci.edu>
 */
//=============================================================================

#ifndef TEST_MODULE_H
#define TEST_MODULE_H

#include /**/ "ace/pre.h"

#include "Test_Client_Module_Export.h"

#if !defined (ACE_LACKS_PRAGMA_ONCE)
# pragma once
#endif /* ACE_LACKS_PRAGMA_ONCE */

#include "ace/Task.h"
#include "ace/Service_Config.h"

#include "TestC.h"

/**
 * @class Test_Client_Module
 *
 * @brief The shared object that is instantiated when the client-side
 *        test module/library is dynamically loaded.
 *
 * This class invokes an operation on a "remote" CORBA object.
 */

class Test_Client_Module_Export Test_Client_Module : public ACE_Task_Base
{
public:

  /// Initializes object when dynamic linking occurs.
  virtual int init (int argc, ACE_TCHAR *argv[]);

  /// Terminates object when dynamic unlinking occurs.
  virtual int fini (void);

  /// Run by a daemon thread to handle deferred processing.
  virtual int svc (void);

private:

  /// Reference to the ORB.
  CORBA::ORB_var orb_;

  /// Reference to the test object.
  Test_var test_;

};

ACE_FACTORY_DECLARE (Test_Client_Module, Test_Client_Module)

#include /**/ "ace/post.h"

#endif  /* TEST_MODULE_H */