sipXcallLib home page


PtProviderListener.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 _PtProviderListener_h_
12 #define _PtProviderListener_h_
13 
14 // SYSTEM INCLUDES
15 // APPLICATION INCLUDES
16 #include "ptapi/PtEventListener.h"
17 // DEFINES
18 // MACROS
19 // EXTERNAL FUNCTIONS
20 // EXTERNAL VARIABLES
21 // CONSTANTS
22 // STRUCTS
23 // TYPEDEFS
24 // FORWARD DECLARATIONS
25 class PtEventListener;
26 class PtProviderEvent;
27 class PtAddressEvent;
28 class PtTerminalEvent;
29 
30 //:The PtProviderListener is used to register with and receive events from
31 //:PtProvider objects.
32 
34 {
35 /* //////////////////////////// PUBLIC //////////////////////////////////// */
36 public:
37 
38 /* ============================ CREATORS ================================== */
39 
40  PtProviderListener(PtEventMask* pMask = NULL);
41  //:Default constructor
43  // in. This must be a subset of the events that the listener supports. The
44  // mask may be NULL where it is assumed that all events applicable to the
45  // derived listener are of interest.
46 
47  PtProviderListener(const PtProviderListener& rPtProviderListener);
48  //:Copy constructor
49 
50  virtual
52  //:Destructor
53 
55  //:Assignment operator
56 /* ============================ MANIPULATORS ============================== */
57 
59  //:Method invoked on listener for event id =
60  //:PROVIDER_EVENT_TRANSMISSION_ENDED
61  //:indicating that the application will no longer receive provider
62  //:events on this instance of the PtProviderListener.
63  // The event parameter is valid only within
64  // this method. The implementation must copy the event if
65  // it is needed beyond the scope of an invocation. The implementation
66  // of this method should not block as it may prevent other listeners
67  // from processing events in a timely fashion.
69 
70  void providerInService(const PtProviderEvent& rEvent);
71  //:Method invoked on listener for event id =
72  //:PROVIDER_IN_SERVICE
73  //:indicating that the state of the PtProvider object has changed to
74  //:PtProvider::IN_SERVICE.
75  // The event parameter is valid only within
76  // this method. The implementation must copy the event if
77  // it is needed beyond the scope of an invocation. The implementation
78  // of this method should not block as it may prevent other listeners
79  // from processing events in a timely fashion.
81 
82  void providerOutOfService(const PtProviderEvent& rEvent);
83  //:Method invoked on listener for event id =
84  //:PROVIDER_OUT_OF_SERVICE
85  //:indicating that the state of the Provider object has changed to
86  //:PtProvider::OUT_OF_SERVICE.
87  // The event parameter is valid only within
88  // this method. The implementation must copy the event if
89  // it is needed beyond the scope of an invocation. The implementation
90  // of this method should not block as it may prevent other listeners
91  // from processing events in a timely fashion.
93 
94  void providerShutdown(const PtProviderEvent& rEvent);
95  //:Method invoked on listener for event id =
96  //:PROVIDER_SHUTDOWN
97  //:indicating that the state of the PtProvider object has changed to
98  //:PtProvider::SHUTDOWN.
99  // The event parameter is valid only within
100  // this method. The implementation must copy the event if
101  // it is needed beyond the scope of an invocation. The implementation
102  // of this method should not block as it may prevent other listeners
103  // from processing events in a timely fashion.
105 
106  void providerAddressAdded(const PtAddressEvent& rEvent);
107  //:Method invoked on listener for event id =
108  //:PROVIDER_ADDRESS_ADDED
109  //:indicating that a new PtAddress has been added to the provider.
110  // The event parameter is valid only within
111  // this method. The implementation must copy the event if
112  // it is needed beyond the scope of an invocation. The implementation
113  // of this method should not block as it may prevent other listeners
114  // from processing events in a timely fashion.
116 
117  void providerAddressRemoved(const PtAddressEvent& rEvent);
118  //:Method invoked on listener for event id =
119  //:PROVIDER_ADDRESS_REMOVED
120  //:indicating that a PtAddress has been removed from the provider.
121  // The event parameter is valid only within
122  // this method. The implementation must copy the event if
123  // it is needed beyond the scope of an invocation. The implementation
124  // of this method should not block as it may prevent other listeners
125  // from processing events in a timely fashion.
127 
128  void providerTerminalAdded(const PtTerminalEvent& rEvent);
129  //:Method invoked on listener for event id =
130  //:PROVIDER_TERMINAL_ADDED
131  //:indicating that a new PtTerminal has been added to the provider.
132  // The event parameter is valid only within
133  // this method. The implementation must copy the event if
134  // it is needed beyond the scope of an invocation. The implementation
135  // of this method should not block as it may prevent other listeners
136  // from processing events in a timely fashion.
138 
139  void providerTerminalRemoved(const PtTerminalEvent& rEvent);
140  //:Method invoked on listener for event id =
141  //:PROVIDER_TERMINAL_REMOVED
142  //:indicating that a PtTerminal has been removed from the provider.
143  // The event parameter is valid only within
144  // this method. The implementation must copy the event if
145  // it is needed beyond the scope of an invocation. The implementation
146  // of this method should not block as it may prevent other listeners
147  // from processing events in a timely fashion.
149 
150 /* ============================ ACCESSORS ================================= */
151 
152 /* ============================ INQUIRY =================================== */
153 
154 /* //////////////////////////// PROTECTED ///////////////////////////////// */
155 protected:
156 
157 /* //////////////////////////// PRIVATE /////////////////////////////////// */
158 private:
159 
160 
161 };
162 
163 /* ============================ INLINE METHODS ============================ */
164 
165 #endif // _PtProviderListener_h_
void providerShutdown(const PtProviderEvent &rEvent)
param: (in) rEvent - Reference to the PtEvent containing the specific event information.
Definition: PtProviderListener.h:33
void providerTerminalRemoved(const PtTerminalEvent &rEvent)
param: (in) rEvent - Reference to the PtEvent containing the specific event information.
void providerAddressRemoved(const PtAddressEvent &rEvent)
param: (in) rEvent - Reference to the PtEvent containing the specific event information.
PtProviderListener(PtEventMask *pMask=NULL)
Definition: PtProviderListener.cpp:32
void providerInService(const PtProviderEvent &rEvent)
param: (in) rEvent - Reference to the PtEvent containing the specific event information.
void providerTerminalAdded(const PtTerminalEvent &rEvent)
param: (in) rEvent - Reference to the PtEvent containing the specific event information.
Definition: PtEventListener.h:55
void providerEventTransmissionEnded(const PtProviderEvent &rEvent)
void providerAddressAdded(const PtAddressEvent &rEvent)
param: (in) rEvent - Reference to the PtEvent containing the specific event information.
void providerOutOfService(const PtProviderEvent &rEvent)
param: (in) rEvent - Reference to the PtEvent containing the specific event information.
PtProviderListener & operator=(const PtProviderListener &rhs)
Definition: PtProviderListener.cpp:46
Definition: PtTerminalEvent.h:32
Definition: PtAddressEvent.h:27
Definition: PtProviderEvent.h:27
Definition: PtEventMask.h:39
virtual ~PtProviderListener()
Definition: PtProviderListener.cpp:40