os/mm/mmlibs/mmfw/src/Client/generic/MclUtil.cpp
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
sl@0
     1
// Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
sl@0
     2
// All rights reserved.
sl@0
     3
// This component and the accompanying materials are made available
sl@0
     4
// under the terms of "Eclipse Public License v1.0"
sl@0
     5
// which accompanies this distribution, and is available
sl@0
     6
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
sl@0
     7
//
sl@0
     8
// Initial Contributors:
sl@0
     9
// Nokia Corporation - initial contribution.
sl@0
    10
//
sl@0
    11
// Contributors:
sl@0
    12
//
sl@0
    13
// Description:
sl@0
    14
//
sl@0
    15
sl@0
    16
// Public Media Server includes
sl@0
    17
#include <mda/client/utility.h>
sl@0
    18
sl@0
    19
#include "CompatAids.h"
sl@0
    20
sl@0
    21
#if defined(__PANIC_COMPAT_IS_ACTIVE)
sl@0
    22
_LIT(KMdaServerName, "CMdaServer");	
sl@0
    23
#endif // __PANIC_COMPAT_IS_ACTIVE			
sl@0
    24
sl@0
    25
// --------------------------------------------------------------
sl@0
    26
// CMdaServer member functions
sl@0
    27
// Public
sl@0
    28
sl@0
    29
/**
sl@0
    30
Connects to and starts the media server.
sl@0
    31
sl@0
    32
@return The connected session with the media server.
sl@0
    33
*/
sl@0
    34
EXPORT_C CMdaServer* CMdaServer::NewL()
sl@0
    35
	{
sl@0
    36
	return new(ELeave) CMdaServer();
sl@0
    37
	}
sl@0
    38
sl@0
    39
/**
sl@0
    40
Destructor. Closes the session with the media server.
sl@0
    41
sl@0
    42
@panic  EMdaUtilServerListenerListNotEmpty 
sl@0
    43
        Not all event listeners that were added to the server have been removed.
sl@0
    44
@panic  EMdaClientBaseSessionHasOpenObjects 
sl@0
    45
        The client has resources still open in the server.
sl@0
    46
*/
sl@0
    47
EXPORT_C CMdaServer::~CMdaServer()
sl@0
    48
	{
sl@0
    49
	}
sl@0
    50
sl@0
    51
/**
sl@0
    52
Adds an object event listener, so that events can be passed to it.
sl@0
    53
sl@0
    54
@param  aListener
sl@0
    55
        The object event listener to add to the list.
sl@0
    56
*/
sl@0
    57
EXPORT_C void CMdaServer::AddListenerL(MMdaObjectEventListener& /*aListener*/)
sl@0
    58
	{
sl@0
    59
	__PANIC_COMPAT(User::Panic(KMdaServerName, KDummyMdaServerNotImplemented));
sl@0
    60
	User::Leave(KErrNotSupported);
sl@0
    61
	}
sl@0
    62
sl@0
    63
/**
sl@0
    64
Removes an object event listener so that events can no longer be passed to it. 
sl@0
    65
The specified listener must be in the list, or a panic occurs.
sl@0
    66
sl@0
    67
@param  aListener
sl@0
    68
        The object event listener to remove from the list.
sl@0
    69
*/
sl@0
    70
EXPORT_C void CMdaServer::RemoveListener(MMdaObjectEventListener& /*aListener*/)
sl@0
    71
	{
sl@0
    72
	__PANIC_COMPAT(User::Panic(KMdaServerName, KDummyMdaServerNotImplemented));
sl@0
    73
	}