live
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | Friends
StreamReplicator Class Reference

#include <StreamReplicator.hh>

Inheritance diagram for StreamReplicator:
Inheritance graph
[legend]
Collaboration diagram for StreamReplicator:
Collaboration graph
[legend]

Public Member Functions

FramedSourcecreateStreamReplica ()
 
unsigned numReplicas () const
 
FramedSourceinputSource () const
 
void detachInputSource ()
 
UsageEnvironmentenvir () const
 
char const * name () const
 
virtual Boolean isSource () const
 
virtual Boolean isSink () const
 
virtual Boolean isRTCPInstance () const
 
virtual Boolean isRTSPClient () const
 
virtual Boolean isRTSPServer () const
 
virtual Boolean isMediaSession () const
 
virtual Boolean isServerMediaSession () const
 

Static Public Member Functions

static StreamReplicatorcreateNew (UsageEnvironment &env, FramedSource *inputSource, Boolean deleteWhenLastReplicaDies=True)
 
static Boolean lookupByName (UsageEnvironment &env, char const *mediumName, Medium *&resultMedium)
 
static void close (UsageEnvironment &env, char const *mediumName)
 
static void close (Medium *medium)
 

Protected Member Functions

 StreamReplicator (UsageEnvironment &env, FramedSource *inputSource, Boolean deleteWhenLastReplicaDies)
 
virtual ~StreamReplicator ()
 
TaskTokennextTask ()
 

Private Member Functions

void getNextFrame (StreamReplica *replica)
 
void deactivateStreamReplica (StreamReplica *replica)
 
void removeStreamReplica (StreamReplica *replica)
 
void afterGettingFrame (unsigned frameSize, unsigned numTruncatedBytes, struct timeval presentationTime, unsigned durationInMicroseconds)
 
void onSourceClosure ()
 
void deliverReceivedFrame ()
 

Static Private Member Functions

static void afterGettingFrame (void *clientData, unsigned frameSize, unsigned numTruncatedBytes, struct timeval presentationTime, unsigned durationInMicroseconds)
 
static void onSourceClosure (void *clientData)
 

Private Attributes

FramedSourcefInputSource
 
Boolean fDeleteWhenLastReplicaDies
 
Boolean fInputSourceHasClosed
 
unsigned fNumReplicas
 
unsigned fNumActiveReplicas
 
unsigned fNumDeliveriesMadeSoFar
 
int fFrameIndex
 
StreamReplicafPrimaryReplica
 
StreamReplicafReplicasAwaitingCurrentFrame
 
StreamReplicafReplicasAwaitingNextFrame
 

Friends

class StreamReplica
 

Detailed Description

Definition at line 30 of file StreamReplicator.hh.

Constructor & Destructor Documentation

◆ StreamReplicator()

StreamReplicator::StreamReplicator ( UsageEnvironment env,
FramedSource inputSource,
Boolean  deleteWhenLastReplicaDies 
)
protected

◆ ~StreamReplicator()

virtual StreamReplicator::~StreamReplicator ( )
protectedvirtual

Member Function Documentation

◆ afterGettingFrame() [1/2]

static void StreamReplicator::afterGettingFrame ( void *  clientData,
unsigned  frameSize,
unsigned  numTruncatedBytes,
struct timeval  presentationTime,
unsigned  durationInMicroseconds 
)
staticprivate

◆ afterGettingFrame() [2/2]

void StreamReplicator::afterGettingFrame ( unsigned  frameSize,
unsigned  numTruncatedBytes,
struct timeval  presentationTime,
unsigned  durationInMicroseconds 
)
private

◆ close() [1/2]

static void Medium::close ( UsageEnvironment env,
char const *  mediumName 
)
staticinherited

◆ close() [2/2]

static void Medium::close ( Medium medium)
staticinherited

◆ createNew()

static StreamReplicator* StreamReplicator::createNew ( UsageEnvironment env,
FramedSource inputSource,
Boolean  deleteWhenLastReplicaDies = True 
)
static

◆ createStreamReplica()

FramedSource* StreamReplicator::createStreamReplica ( )

◆ deactivateStreamReplica()

void StreamReplicator::deactivateStreamReplica ( StreamReplica replica)
private

◆ deliverReceivedFrame()

void StreamReplicator::deliverReceivedFrame ( )
private

◆ detachInputSource()

void StreamReplicator::detachInputSource ( )
inline

Definition at line 47 of file StreamReplicator.hh.

47 { fInputSource = NULL; }
FramedSource * fInputSource
#define NULL

References fInputSource, and NULL.

◆ envir()

UsageEnvironment& Medium::envir ( ) const
inlineinherited

◆ getNextFrame()

void StreamReplicator::getNextFrame ( StreamReplica replica)
private

◆ inputSource()

FramedSource* StreamReplicator::inputSource ( ) const
inline

Definition at line 44 of file StreamReplicator.hh.

44 { return fInputSource; }
FramedSource * fInputSource

References fInputSource.

◆ isMediaSession()

virtual Boolean Medium::isMediaSession ( ) const
virtualinherited

Reimplemented in MediaSession.

◆ isRTCPInstance()

virtual Boolean Medium::isRTCPInstance ( ) const
virtualinherited

Reimplemented in RTCPInstance.

◆ isRTSPClient()

virtual Boolean Medium::isRTSPClient ( ) const
virtualinherited

Reimplemented in RTSPClient.

◆ isRTSPServer()

virtual Boolean Medium::isRTSPServer ( ) const
virtualinherited

Reimplemented in RTSPServer.

◆ isServerMediaSession()

virtual Boolean Medium::isServerMediaSession ( ) const
virtualinherited

Reimplemented in ServerMediaSession.

◆ isSink()

virtual Boolean Medium::isSink ( ) const
virtualinherited

Reimplemented in MediaSink.

◆ isSource()

virtual Boolean Medium::isSource ( ) const
virtualinherited

Reimplemented in MediaSource.

◆ lookupByName()

static Boolean Medium::lookupByName ( UsageEnvironment env,
char const *  mediumName,
Medium *&  resultMedium 
)
staticinherited

◆ name()

char const* Medium::name ( ) const
inlineinherited

Definition at line 61 of file Media.hh.

61 {return fMediumName;}
char fMediumName[mediumNameMaxLen]
Definition: Media.hh:83

References Medium::fMediumName.

◆ nextTask()

TaskToken& Medium::nextTask ( )
inlineprotectedinherited

Definition at line 77 of file Media.hh.

77  {
78  return fNextTask;
79  }
TaskToken fNextTask
Definition: Media.hh:84

References Medium::fNextTask.

◆ numReplicas()

unsigned StreamReplicator::numReplicas ( ) const
inline

Definition at line 42 of file StreamReplicator.hh.

42 { return fNumReplicas; }

References fNumReplicas.

◆ onSourceClosure() [1/2]

static void StreamReplicator::onSourceClosure ( void *  clientData)
staticprivate

◆ onSourceClosure() [2/2]

void StreamReplicator::onSourceClosure ( )
private

◆ removeStreamReplica()

void StreamReplicator::removeStreamReplica ( StreamReplica replica)
private

Friends And Related Function Documentation

◆ StreamReplica

friend class StreamReplica
friend

Definition at line 56 of file StreamReplicator.hh.

Field Documentation

◆ fDeleteWhenLastReplicaDies

Boolean StreamReplicator::fDeleteWhenLastReplicaDies
private

Definition at line 76 of file StreamReplicator.hh.

◆ fFrameIndex

int StreamReplicator::fFrameIndex
private

Definition at line 78 of file StreamReplicator.hh.

◆ fInputSource

FramedSource* StreamReplicator::fInputSource
private

Definition at line 75 of file StreamReplicator.hh.

Referenced by detachInputSource(), and inputSource().

◆ fInputSourceHasClosed

Boolean StreamReplicator::fInputSourceHasClosed
private

Definition at line 76 of file StreamReplicator.hh.

◆ fNumActiveReplicas

unsigned StreamReplicator::fNumActiveReplicas
private

Definition at line 77 of file StreamReplicator.hh.

◆ fNumDeliveriesMadeSoFar

unsigned StreamReplicator::fNumDeliveriesMadeSoFar
private

Definition at line 77 of file StreamReplicator.hh.

◆ fNumReplicas

unsigned StreamReplicator::fNumReplicas
private

Definition at line 77 of file StreamReplicator.hh.

Referenced by numReplicas().

◆ fPrimaryReplica

StreamReplica* StreamReplicator::fPrimaryReplica
private

Definition at line 80 of file StreamReplicator.hh.

◆ fReplicasAwaitingCurrentFrame

StreamReplica* StreamReplicator::fReplicasAwaitingCurrentFrame
private

Definition at line 81 of file StreamReplicator.hh.

◆ fReplicasAwaitingNextFrame

StreamReplica* StreamReplicator::fReplicasAwaitingNextFrame
private

Definition at line 82 of file StreamReplicator.hh.


The documentation for this class was generated from the following file: