upnpavcontroller/upnpavcontrollerclient/inc/upnpavrenderingsessionobserver.h
changeset 0 7f85d04be362
child 38 5360b7ddc251
equal deleted inserted replaced
-1:000000000000 0:7f85d04be362
       
     1 /*
       
     2 * Copyright (c) 2006 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:      callback interface for a rendering session
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 
       
    22 
       
    23 #ifndef M_UPNPAVRENDERINGSESSIONOBSERVER_H
       
    24 #define M_UPNPAVRENDERINGSESSIONOBSERVER_H
       
    25 
       
    26 // INCLUDE FILES
       
    27 #include "upnpavsessionobserverbase.h"
       
    28 
       
    29 // TYPEDEFS
       
    30 enum TUPnPAVInteractOperation
       
    31     {
       
    32     EUPnPAVPlay = 0,
       
    33     EUPnPAVPause,
       
    34     EUPnPAVStop,
       
    35     EUPnPAVPlayUser,
       
    36     EUPnPAVPauseUser,
       
    37     EUPnPAVStopUser
       
    38     };
       
    39 
       
    40 /**
       
    41 * Defines the response interface for the media control operations of the
       
    42 * UPnP AV Controller.
       
    43 *
       
    44 * @since Series 60 3.1
       
    45 */
       
    46 class MUPnPAVRenderingSessionObserver : public MUPnPAVSessionObserverBase
       
    47     {
       
    48     
       
    49 public:
       
    50 
       
    51     /**
       
    52      * UPnP AV Controller calls this method to return the result for the
       
    53      * 'get volume' request. Parameter contains the volume level of the
       
    54      * media renderer device to which the 'get volume' request was sent.
       
    55      *
       
    56      * @since Series 60 3.1
       
    57      * @param aError system wide error code
       
    58      * @param aVolumeLevel TInt volume level (integer value between 0 - 100)
       
    59      * @param aActionResponse ETrue, if this is a response to GetVolume()
       
    60      * @return None
       
    61      */
       
    62     virtual void VolumeResult( TInt aError, TInt aVolumeLevel,
       
    63         TBool aActionResponse ) = 0;
       
    64 
       
    65     /**
       
    66      * UPnP AV Controller calls this method to return the result for the
       
    67      * 'get mute' request. Parameter contains the state of the mute of the
       
    68      * media renderer device to which the 'get mute' request was sent.
       
    69      *
       
    70      * @since Series 60 3.1
       
    71      * @param aError system wide error code
       
    72      * @param aMute TBool the state of the mute (ETrue or EFalse)
       
    73      * @param aActionResponse ETrue, if this is a response to GetMute()
       
    74      * @return None
       
    75      */
       
    76     virtual void MuteResult( TInt aError, TBool aMute,
       
    77         TBool aActionResponse ) = 0;
       
    78 
       
    79     /**
       
    80      * UPnP AV Controller calls this method to indicate that the requested
       
    81      * interaction operation (play, stop, etc.) is complete. In other words,
       
    82      * the target rendering device has changed it's state accordingly.
       
    83      *
       
    84      * @since Series 60 3.1
       
    85      * @param aError system wide error code
       
    86      * @param aOperation TInt operation (TAVInteractOperation)
       
    87      * @return None
       
    88      */
       
    89     virtual void InteractOperationComplete( 
       
    90                       TInt aError,
       
    91                       TUPnPAVInteractOperation aOperation 
       
    92                       ) = 0;
       
    93 
       
    94     /**
       
    95      * UPnP AV Controller calls this method as a response to Position 
       
    96      * Info action. The current position and the total length of the 
       
    97      * track that is currently playing is returned. The results are in
       
    98      * (hh:mm:ss) format.
       
    99      *
       
   100      * UPnPAVController releases the memory allocated for aTrackPosition
       
   101      * and aTrackLength.
       
   102      *
       
   103      * @since Series 60 3.0
       
   104      * @param aStatus TInt error code
       
   105      * @param aTrackPosition TDesC8& track position
       
   106      * @param aTrackLength TDesC8& track length
       
   107      * @return None
       
   108      */
       
   109     virtual void PositionInfoResult( 
       
   110                       TInt aError, 
       
   111                       const TDesC8& aTrackPosition, 
       
   112                       const TDesC8& aTrackLength 
       
   113                       ) = 0;
       
   114 
       
   115     /**
       
   116      * UPnP AV Controller calls this method to return the result for the
       
   117      * 'set uri' request.
       
   118      *
       
   119      * @since Series 60 3.1
       
   120      * @param aError error code
       
   121      * @return None
       
   122      */                      
       
   123     virtual void SetURIResult( TInt aError ) = 0;
       
   124 
       
   125     /**
       
   126      * UPnP AV Controller calls this method to return the result for the
       
   127      * 'set next uri' request.
       
   128      *
       
   129      * @since Series 60 3.1
       
   130      * @param aError error code
       
   131      * @return None
       
   132      */                         
       
   133     virtual void SetNextURIResult( TInt aError ) = 0;                   
       
   134 
       
   135     /**
       
   136      * Notifies that the Media Renderer we have a session with has
       
   137      * disappeared. Session is now unusable and must be closed. 
       
   138      *
       
   139      * @since Series 60 3.1
       
   140      * @return None
       
   141      */        
       
   142     virtual void MediaRendererDisappeared( 
       
   143         TUPnPDeviceDisconnectedReason aReason ) = 0;
       
   144         
       
   145     virtual void ReserveLocalMSServicesCompleted( TInt aError ) = 0;        
       
   146 
       
   147     };
       
   148 
       
   149 #endif // M_UPNPAVRENDERINGSESSIONOBSERVER_H
       
   150 
       
   151 // End of File