sipXcallLib home page


PtComponent.h
Go to the documentation of this file.
1 //
2 // Copyright (C) 2004-2006 SIPfoundry Inc.
3 // Licensed by SIPfoundry under the LGPL license.
4 //
5 // Copyright (C) 2004-2006 Pingtel Corp. All rights reserved.
6 // Licensed to SIPfoundry under a Contributor Agreement.
7 //
8 // $$
10 
11 #ifndef _PtComponent_h_
12 #define _PtComponent_h_
13 
14 // SYSTEM INCLUDES
15 // APPLICATION INCLUDES
16 #include "PtDefs.h"
17 
18 // DEFINES
19 // MACROS
20 // EXTERNAL FUNCTIONS
21 // EXTERNAL VARIABLES
22 // CONSTANTS
23 // STRUCTS
24 // TYPEDEFS
25 // FORWARD DECLARATIONS
26 
27 //:The PtComponent class is the base class for all individual components used
28 //:to model telephone hardware. Each distinct component type is derived from
29 //:this class.
31 {
32 /* //////////////////////////// PUBLIC //////////////////////////////////// */
33 public:
34 
36  {
48  };
49 
50 /* ============================ CREATORS ================================== */
51  PtComponent();
52 
53  PtComponent(const PtComponent& rPtComponent);
54  //:Copy constructor (not implemented for this class)
55 
56  PtComponent& operator=(const PtComponent& rhs);
57  //:Assignment operator (not implemented for this class)
58 
59  PtComponent(int componentType);
60  //:Constructor
62 
63  PtComponent(const char*& rName);
64  //:Constructor
76 
77  virtual
78  ~PtComponent();
79  //:Destructor
80 
81 /* ============================ MANIPULATORS ============================== */
82  void setGroupType(int groupType);
83 
84 /* ============================ ACCESSORS ================================= */
85 
86  virtual PtStatus getName(char* rpName, int maxLen);
87  //:Returns the name associated with this component.
91 
92  virtual PtStatus getType(int& rType);
93  //:Returns the type associated with this component.
97 
98 /* ============================ INQUIRY =================================== */
99 
100 friend class PtTerminal;
101 friend class PtPhoneTerminal;
102 friend class PtComponentGroup;
103 
104 /* //////////////////////////// PROTECTED ///////////////////////////////// */
105 protected:
106  int mType;
107  char mpName[21];
108 public:
110 
111 
112 /* //////////////////////////// PRIVATE /////////////////////////////////// */
113 private:
114 
115 
116 };
117 
118 /* ============================ INLINE METHODS ============================ */
119 
120 #endif // _PtComponent_h_
PtComponent & operator=(const PtComponent &rhs)
Definition: PtComponent.cpp:158
PtStatus
Definition: PtDefs.h:49
int mType
Definition: PtComponent.h:106
Definition: PtComponent.h:37
Definition: PtComponent.h:45
ComponentType
Definition: PtComponent.h:35
Definition: PtComponent.h:40
virtual PtStatus getName(char *rpName, int maxLen)
Definition: PtComponent.cpp:181
Definition: PtComponent.h:30
Definition: PtComponent.h:38
PtComponent()
Definition: PtComponent.cpp:30
int mGroupType
Definition: PtComponent.h:109
Definition: PtPhoneTerminal.h:50
Definition: PtComponent.h:43
Definition: PtComponent.h:41
void setGroupType(int groupType)
Definition: PtComponent.cpp:208
virtual ~PtComponent()
param: rName - The name of telephone hardware modeled by this component name: button name: hookswitch...
Definition: PtComponent.cpp:150
Definition: PtComponent.h:44
Definition: PtComponent.h:42
virtual PtStatus getType(int &rType)
param: (out) rpName - The reference used to return the name retcode: PT_SUCCESS - Success retcode: PT...
Definition: PtComponent.cpp:199
char mpName[21]
Definition: PtComponent.h:107
Definition: PtTerminal.h:178
Definition: PtComponent.h:39
Definition: PtComponent.h:47
Definition: PtComponent.h:46
Definition: PtComponentGroup.h:37