sipxmedialib  Version 3.3
MprRtpInputConnectionConstructor.h
Go to the documentation of this file.
1 //
2 // Copyright (C) 2006-2011 SIPfoundry Inc. All rights reserved.
3 // Licensed by SIPfoundry under the LGPL license.
4 //
5 // Copyright (C) 2006-2008 SIPez LLC.
6 // Licensed to SIPfoundry under a Contributor Agreement.
7 //
8 // $$
10 
11 // Author: Dan Petrie <dpetrie AT SIPez DOT com>
12 
13 #ifndef _MprRtpInputConnectionConstructor_h_
14 #define _MprRtpInputConnectionConstructor_h_
15 
16 // SYSTEM INCLUDES
17 // APPLICATION INCLUDES
20 #include <mp/MprRtpDispatcher.h>
21 #include <mp/MprToSpkr.h>
22 
23 // DEFINES
24 // MACROS
25 // EXTERNAL FUNCTIONS
26 // EXTERNAL VARIABLES
27 // CONSTANTS
28 // STRUCTS
29 // TYPEDEFS
30 // FORWARD DECLARATIONS
31 
37 {
38 /* //////////////////////////// PUBLIC //////////////////////////////////// */
39 public:
40 
41 /* ============================ CREATORS ================================== */
42 
45  int numRtpStreams = 1)
48  0, 0, //minInputs, maxInputs,
49  0, numRtpStreams) //minOutputs, maxOutputs
50  , mNumRtpStreams(numRtpStreams)
51  , mIsMcast(isMcast)
52  {
53  }
54 
57 
58 /* ============================ MANIPULATORS ============================== */
59 
61  virtual OsStatus newResource(const UtlString& resourceName,
62  int maxResourcesToCreate,
63  int& numResourcesCreated,
64  MpResource* resourceArray[])
65  {
66  assert(maxResourcesToCreate >= 1);
67  numResourcesCreated = 1;
71  resourceArray[0] = new MpRtpInputConnection(resourceName,
72  -1,
73  NULL,
75  streamAffinity);
76  resourceArray[0]->enable();
77  return(OS_SUCCESS);
78  }
79 
80 /* ============================ ACCESSORS ================================= */
81 
82 /* ============================ INQUIRY =================================== */
83 
84 /* //////////////////////////// PROTECTED ///////////////////////////////// */
85 protected:
86 
87 /* //////////////////////////// PRIVATE /////////////////////////////////// */
88 private:
89 
91  UtlBoolean mIsMcast;
92 
94  MprRtpInputConnectionConstructor(const MprRtpInputConnectionConstructor& rMprRtpInputConnectionConstructor);
95 
96 
99 
100 };
101 
102 /* ============================ INLINE METHODS ============================ */
103 
104 #endif // _MprRtpInputConnectionConstructor_h_
MprRtpInputConnectionConstructor & operator=(const MprRtpInputConnectionConstructor &rhs)
Disabled assignment operator.
RtpStreamAffinity
Definition: MprRtpDispatcher.h:47
int mNumRtpStreams
Definition: MprRtpInputConnectionConstructor.h:90
virtual ~MprRtpInputConnectionConstructor()
Destructor.
Definition: MprRtpInputConnectionConstructor.h:56
Connection container for the inbound and outbound network paths to a single remote party...
Definition: MpRtpInputConnection.h:46
#define DEFAULT_RTP_INPUT_RESOURCE_TYPE
Definition: MpResourceFactory.h:29
#define DEFAULT_MCAST_RTP_INPUT_RESOURCE_TYPE
Definition: MpResourceFactory.h:30
virtual OsStatus newResource(const UtlString &resourceName, int maxResourcesToCreate, int &numResourcesCreated, MpResource *resourceArray[])
Create a new resource.
Definition: MprRtpInputConnectionConstructor.h:61
virtual UtlBoolean enable()
Enable this resource.
Definition: MpResource.cpp:145
MprRtpInputConnectionConstructor is used to construct a MprRtpInputConnection resource.
Definition: MprRtpInputConnectionConstructor.h:36
UtlBoolean mIsMcast
Definition: MprRtpInputConnectionConstructor.h:91
Definition: MprRtpDispatcher.h:49
Abstract base class for all media processing objects.
Definition: MpResource.h:56
MpAudioResourceConstructor is used to construct a specific audio resource type.
Definition: MpAudioResourceConstructor.h:36
MprRtpInputConnectionConstructor(UtlBoolean isMcast=FALSE, int numRtpStreams=1)
Constructor.
Definition: MprRtpInputConnectionConstructor.h:44
#define FALSE
Definition: PlgDefsV1.h:37
Definition: MprRtpDispatcher.h:50