os/mm/mmtestenv/mmtestfw/include/TestFrameworkIpc.h
author sl@SLION-WIN7.fritz.box
Fri, 15 Jun 2012 03:10:57 +0200
changeset 0 bde4ae8d615e
permissions -rw-r--r--
First public contribution.
sl@0
     1
// Copyright (c) 2003-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
// Extensions to mmfipc. for testframework - support Des16's as well as Des8's
sl@0
    15
// 
sl@0
    16
//
sl@0
    17
sl@0
    18
#ifndef __TESTFRAMEWORKIPC_H__
sl@0
    19
#define __TESTFRAMEWORKIPC_H__
sl@0
    20
sl@0
    21
#include <mmf/common/mmfipc.h>
sl@0
    22
#ifdef SYMBIAN_ENABLE_SPLIT_HEADERS
sl@0
    23
#include <mmf/common/mmfipcserver.h>
sl@0
    24
#endif
sl@0
    25
/**
sl@0
    26
 * Add additional SendReceive() call to RMmfSessionBase.
sl@0
    27
 * This class adds a TDesC16 call to the standard set.
sl@0
    28
 *
sl@0
    29
 * @internalTechnology
sl@0
    30
 */
sl@0
    31
 
sl@0
    32
class RMmfSessionBaseX : public RMmfSessionBase
sl@0
    33
	{
sl@0
    34
protected:
sl@0
    35
	// following replaces "using RMmfSessionBase::SendReceive;" since does not work on gcc
sl@0
    36
	TInt SendReceive(TInt aFunction) const;
sl@0
    37
	void SendReceive(TInt aFunction, TRequestStatus& aStatus) const;
sl@0
    38
	TInt SendReceive(TInt aFunction, TInt aParam0) const;
sl@0
    39
	TInt SendReceive(TInt aFunction, TInt aParam0, TInt aParam1) const;
sl@0
    40
	void SendReceive(TInt aFunction, TInt aParam0, TRequestStatus& aStatus) const;
sl@0
    41
	void SendReceive(TInt aFunction, TInt aParam0, TInt aParam1, TRequestStatus& aStatus) const;
sl@0
    42
	TInt SendReceive(TInt aFunction, const TDesC8& aParam0) const;
sl@0
    43
	TInt SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1) const;
sl@0
    44
	TInt SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1, const TDesC8& aParam2) const;
sl@0
    45
	void SendReceive(TInt aFunction, const TDesC8& aParam0, TRequestStatus& aStatus) const;
sl@0
    46
	void SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1, TRequestStatus& aStatus) const;
sl@0
    47
	void SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1, const TDesC8& aParam2, TRequestStatus& aStatus) const;
sl@0
    48
sl@0
    49
	// additional call
sl@0
    50
	TInt SendReceive(TInt aFunction, const TDesC& aParam0, TInt aParam1) const;
sl@0
    51
	};
sl@0
    52
sl@0
    53
/**
sl@0
    54
 * Add additional calls to MmfMessageUtil.
sl@0
    55
 * This class adds TDes(C)16 calls to the basic set.
sl@0
    56
 * 
sl@0
    57
 * @internalTechnology
sl@0
    58
 */
sl@0
    59
sl@0
    60
class MmfMessageUtilX : public MmfMessageUtil
sl@0
    61
	{
sl@0
    62
public:
sl@0
    63
	// import existing API
sl@0
    64
	// the following replaces "using MmfMessageUtil::..." since that does not on gcc
sl@0
    65
	static TInt Read(const RMmfIpcMessage& aMessage, TInt aParam, TDes8& aResult);
sl@0
    66
	static TInt Write(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC8& aValue);
sl@0
    67
	static void ReadL(const RMmfIpcMessage& aMessage, TInt aParam, TDes8& aResult);
sl@0
    68
	static void WriteL(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC8& aValue);
sl@0
    69
sl@0
    70
	// new 16-bit descriptor variants
sl@0
    71
	static TInt Read(const RMmfIpcMessage& aMessage, TInt aParam, TDes16& aResult);
sl@0
    72
	static TInt Write(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC16& aValue);
sl@0
    73
	static void ReadL(const RMmfIpcMessage& aMessage, TInt aParam, TDes16& aResult);
sl@0
    74
	static void WriteL(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC16& aValue);
sl@0
    75
	};
sl@0
    76
sl@0
    77
#include <testframeworkipc.inl>
sl@0
    78
sl@0
    79
#endif // __TESTFRAMEWORKIPC_H__