# rtpep.h

Go to the documentation of this file.

    00001 /*
    00002  * Endpoint abstraction
    00003  *
    00004  * Open Phone Abstraction Library (OPAL)
    00005  *
    00006  * Copyright (C) 2007 Post Increment
    00007  *
    00008  * The contents of this file are subject to the Mozilla Public License
    00009  * Version 1.0 (the "License"); you may not use this file except in
    00010  * compliance with the License. You may obtain a copy of the License at
    00011  * http://www.mozilla.org/MPL/
    00012  *
    00013  * Software distributed under the License is distributed on an "AS IS"
    00014  * basis, WITHOUT WARRANTY OF ANY KIND, either express or implied. See
    00015  * the License for the specific language governing rights and limitations
    00016  * under the License.
    00017  *
    00018  * The Original Code is Open Phone Abstraction Library.
    00019  *
    00020  * The Initial Developer of the Original Code is Post Increment
    00021  *
    00022  * Contributor(s): ______________________________________.
    00023  *
    00024  * $Revision: 20384 $
    00025  * $Author: rjongbloed $
    00026  * $Date: 2008-06-04 10:14:22 +0000 (Wed, 04 Jun 2008) $
    00027  */
    00028
    00029 #ifndef __OPAL_RTPEP_H
    00030 #define __OPAL_RTPEP_H
    00031
    00032 #ifdef P_USE_PRAGMA
    00033 #pragma interface
    00034 #endif
    00035
    00036 #include <opal/buildopts.h>
    00037
    00038 #include <opal/endpoint.h>
    00039
    00040 class OpalRTPEndPoint : public OpalEndPoint
    00041 {
    00042   PCLASSINFO(OpalRTPEndPoint, OpalEndPoint);
    00043
    00048     OpalRTPEndPoint(
    00049       OpalManager & manager,
    00050       const PCaselessString & prefix,
    00051       unsigned attributes
    00052     );
    00053
    00056     ~OpalRTPEndPoint();
    00057
    00058 #if OPAL_RTP_AGGREGATE
    00059
    00060     virtual PBoolean UseRTPAggregation() const;
    00061
    00064     void SetRTPAggregationSize(
    00065       PINDEX size
    00066     );
    00067
    00070     PINDEX GetRTPAggregationSize() const;
    00071
    00074     PHandleAggregator * GetRTPAggregator();
    00075
    00076 #endif
    00077
    00081     virtual PBoolean AdjustInterfaceTable(PIPSocket::Address & remoteAddress,
    00082                                       PIPSocket::InterfaceTable & interfaceTable);
    00083
    00101     virtual PBoolean IsRTPNATEnabled(
    00102       OpalConnection & connection,
    00103       const PIPSocket::Address & localAddr,
    00104       const PIPSocket::Address & peerAddr,
    00105       const PIPSocket::Address & signalAddr,
    00106       PBoolean incoming
    00107     );
    00108
    00109     virtual void SetDefaultSecurityMode(const PString & v)
    00110     { defaultSecurityMode = v; }
    00111
    00112     virtual PString GetDefaultSecurityMode() const
    00113     { return defaultSecurityMode; }
    00114
    00124     virtual OpalMediaFormatList GetMediaFormats() const;
    00126
    00127   protected:
    00128     PString defaultSecurityMode;
    00129
    00130 #if OPAL_RTP_AGGREGATE
    00131     PMutex rtpAggregationMutex;
    00132     PBoolean useRTPAggregation;
    00133     PINDEX rtpAggregationSize;
    00134     PHandleAggregator * rtpAggregator;
    00135 #endif
    00136
    00138 };
    00139
    00140
    00141 #endif // __OPAL_RTPEP_H