multimediacommsengine/mmceshared/inc/mcecomspeakersink.h
changeset 0 1bce908db942
equal deleted inserted replaced
-1:000000000000 0:1bce908db942
       
     1 /*
       
     2 * Copyright (c) 2005 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 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 #ifndef CMCECOMSPEAKERSINK_H
       
    22 #define CMCECOMSPEAKERSINK_H
       
    23 
       
    24 #include <e32std.h>  
       
    25 #include "mcecommediasink.h"
       
    26 
       
    27 /**
       
    28  * 
       
    29  *
       
    30  * @lib 
       
    31  */
       
    32 class CMceComSpeakerSink : public CMceComMediaSink
       
    33 	{
       
    34 
       
    35 public: // Constructors and destructor
       
    36 
       
    37     /**
       
    38     * Constructor
       
    39     */
       
    40     static CMceComSpeakerSink* NewL();
       
    41 
       
    42     /**
       
    43     * Constructor
       
    44     */
       
    45     static CMceComSpeakerSink* NewLC();
       
    46 
       
    47     /**
       
    48     * Destructor.
       
    49     */
       
    50 	~CMceComSpeakerSink();
       
    51 
       
    52 public: // from CMceComMediaSink
       
    53 
       
    54     /**
       
    55     * Internalizes flat data
       
    56     * @param aReadStream read stream
       
    57     */
       
    58     void InternalizeFlatL( RReadStream& aReadStream );
       
    59 
       
    60     /**
       
    61     * Externalizes flat data
       
    62     * @param aWriteStream write stream
       
    63     */
       
    64     void ExternalizeFlatL( RWriteStream& aWriteStream );
       
    65 
       
    66     /**
       
    67     * Traversal event handler
       
    68     * @param aEvent the event
       
    69     * @return status, if event was consumed or not or object needs update
       
    70     */
       
    71     TInt EventReceivedL( TMceComEvent& aEvent );
       
    72 
       
    73     /**
       
    74     * Clones this object
       
    75     * @return the cloned object
       
    76     */
       
    77     CMceComMediaSink* CloneL();
       
    78 
       
    79     /**
       
    80     * Updates this object
       
    81     * @param aUpdate object updates this
       
    82     */
       
    83     void UpdateL( CMceComMediaSink& aUpdate );
       
    84 
       
    85 
       
    86     /**
       
    87     * Called endpoint proxy must be created
       
    88     * @return endpointProxy
       
    89     */
       
    90     MMceComEndPointProxy* CreateEndpointProxyL() const;
       
    91 
       
    92     /**
       
    93     * Should this endpoint use endpoint proxy
       
    94     * @return ETrue, this endpoint uses endpoint proxy
       
    95     */
       
    96     TBool UsesEndpointProxy() const;
       
    97 
       
    98     /**
       
    99     * Is this endpoint re-usable
       
   100     * @return ETrue, if this endpoint is re-usable
       
   101     */
       
   102     TBool Reusable( const CMceComMediaStream& aParent ) const;
       
   103 
       
   104 #ifdef MCE_COMMON_SERVER_SIDE
       
   105 
       
   106     /**
       
   107     * Returns mcc type for mcc endpoint
       
   108     * @return mcc type
       
   109     */
       
   110     const TUid MccType();
       
   111     
       
   112     /**
       
   113     * Returns init param for mcc endpoint
       
   114     * @param aCodec codec
       
   115     * @return init param
       
   116     */
       
   117     const TDesC8& InitParamL( const CMceComCodec& aCodec );
       
   118     
       
   119     /**
       
   120     * Prepares this endpoint
       
   121     */
       
   122     void PrepareL();
       
   123     
       
   124 
       
   125 #endif//MCE_COMMON_SERVER_SIDE
       
   126 
       
   127 protected:
       
   128 
       
   129     /**
       
   130     * C++ default constructor.
       
   131     */
       
   132 	CMceComSpeakerSink();
       
   133 	
       
   134 	
       
   135 
       
   136 
       
   137 public: // Data
       
   138 
       
   139     /**
       
   140     * Audio route
       
   141     */
       
   142     TInt iAudioRoute;
       
   143     
       
   144     /**
       
   145     * Audio volume
       
   146     */
       
   147     TInt iVolume;
       
   148 
       
   149 	};
       
   150 
       
   151 
       
   152 #endif