realtimenetprots/sipfw/ClientResolver/Resolver/inc/CSdpRtpmapStrategy.h
changeset 0 307788aac0a8
equal deleted inserted replaced
-1:000000000000 0:307788aac0a8
       
     1 /*
       
     2 * Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:
       
    15 * Name          : CSdpRtpmapStrategy.h
       
    16 * Part of       : SIP Client Resolver
       
    17 * Version       : 1.0
       
    18 *
       
    19 */
       
    20 
       
    21 
       
    22 
       
    23 
       
    24 /**
       
    25  @internalComponent
       
    26 */
       
    27 
       
    28 #ifndef CSDPRTPMAPSTRATEGY_H
       
    29 #define CSDPRTPMAPSTRATEGY_H
       
    30 
       
    31 #include <e32base.h>
       
    32 #include <stringpool.h>
       
    33 #include "CSdpMLineStrategyBase.h"
       
    34 #include "sdpfmtattributefield.h"
       
    35 
       
    36 
       
    37 class CSdpRtpmapStrategy : public CSdpMLineStrategyBase
       
    38     {
       
    39 public:
       
    40 
       
    41     static CSdpRtpmapStrategy* NewLC(const MSipClients& aSipClients);
       
    42     ~CSdpRtpmapStrategy ();
       
    43 
       
    44 protected: // From CSdpMLineStrategyBase
       
    45 
       
    46     TBool IsApplicable(CSdpMediaField& aMediaField);
       
    47 
       
    48     TBool FieldsMatchL(const CSdpMediaField& aReceivedMedia,
       
    49                        const CSdpMediaField& aClientMedia);
       
    50 
       
    51 private:
       
    52 
       
    53     CSdpRtpmapStrategy(const MSipClients& aSipClients);
       
    54     void ConstructL();
       
    55     
       
    56     TBool HasMatchingRtpmapAttritbute(
       
    57         const CSdpMediaField& aMediaField,
       
    58         const CSdpFmtAttributeField& aAttribute);
       
    59 
       
    60     TBool HasMatchingFormatsL(
       
    61         const CSdpMediaField& aReceivedMedia,
       
    62         const CSdpMediaField& aClientMedia) const;
       
    63 
       
    64     RArray<TUint> ExtractFormatsL(const TDesC8& aFormats) const;
       
    65     
       
    66 private: // Data
       
    67     
       
    68     RStringF iApplicationStringF;
       
    69     RStringF iRtpAvpStringF;
       
    70     RStringF iRtpmapStringF;
       
    71     
       
    72 private: // For testing purposes
       
    73 
       
    74 	UNIT_TEST(CSdpRtpmapStrategyTest)
       
    75     };
       
    76 
       
    77 #endif // CSDPMLINENAMESTRATEGY_H
       
    78 
       
    79 // End of File