1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/os/mm/mmtestenv/mmtestfw/include/TestFrameworkIpc.h Fri Jun 15 03:10:57 2012 +0200
1.3 @@ -0,0 +1,79 @@
1.4 +// Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
1.5 +// All rights reserved.
1.6 +// This component and the accompanying materials are made available
1.7 +// under the terms of "Eclipse Public License v1.0"
1.8 +// which accompanies this distribution, and is available
1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.10 +//
1.11 +// Initial Contributors:
1.12 +// Nokia Corporation - initial contribution.
1.13 +//
1.14 +// Contributors:
1.15 +//
1.16 +// Description:
1.17 +// Extensions to mmfipc. for testframework - support Des16's as well as Des8's
1.18 +//
1.19 +//
1.20 +
1.21 +#ifndef __TESTFRAMEWORKIPC_H__
1.22 +#define __TESTFRAMEWORKIPC_H__
1.23 +
1.24 +#include <mmf/common/mmfipc.h>
1.25 +#ifdef SYMBIAN_ENABLE_SPLIT_HEADERS
1.26 +#include <mmf/common/mmfipcserver.h>
1.27 +#endif
1.28 +/**
1.29 + * Add additional SendReceive() call to RMmfSessionBase.
1.30 + * This class adds a TDesC16 call to the standard set.
1.31 + *
1.32 + * @internalTechnology
1.33 + */
1.34 +
1.35 +class RMmfSessionBaseX : public RMmfSessionBase
1.36 + {
1.37 +protected:
1.38 + // following replaces "using RMmfSessionBase::SendReceive;" since does not work on gcc
1.39 + TInt SendReceive(TInt aFunction) const;
1.40 + void SendReceive(TInt aFunction, TRequestStatus& aStatus) const;
1.41 + TInt SendReceive(TInt aFunction, TInt aParam0) const;
1.42 + TInt SendReceive(TInt aFunction, TInt aParam0, TInt aParam1) const;
1.43 + void SendReceive(TInt aFunction, TInt aParam0, TRequestStatus& aStatus) const;
1.44 + void SendReceive(TInt aFunction, TInt aParam0, TInt aParam1, TRequestStatus& aStatus) const;
1.45 + TInt SendReceive(TInt aFunction, const TDesC8& aParam0) const;
1.46 + TInt SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1) const;
1.47 + TInt SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1, const TDesC8& aParam2) const;
1.48 + void SendReceive(TInt aFunction, const TDesC8& aParam0, TRequestStatus& aStatus) const;
1.49 + void SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1, TRequestStatus& aStatus) const;
1.50 + void SendReceive(TInt aFunction, const TDesC8& aParam0, const TDesC8& aParam1, const TDesC8& aParam2, TRequestStatus& aStatus) const;
1.51 +
1.52 + // additional call
1.53 + TInt SendReceive(TInt aFunction, const TDesC& aParam0, TInt aParam1) const;
1.54 + };
1.55 +
1.56 +/**
1.57 + * Add additional calls to MmfMessageUtil.
1.58 + * This class adds TDes(C)16 calls to the basic set.
1.59 + *
1.60 + * @internalTechnology
1.61 + */
1.62 +
1.63 +class MmfMessageUtilX : public MmfMessageUtil
1.64 + {
1.65 +public:
1.66 + // import existing API
1.67 + // the following replaces "using MmfMessageUtil::..." since that does not on gcc
1.68 + static TInt Read(const RMmfIpcMessage& aMessage, TInt aParam, TDes8& aResult);
1.69 + static TInt Write(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC8& aValue);
1.70 + static void ReadL(const RMmfIpcMessage& aMessage, TInt aParam, TDes8& aResult);
1.71 + static void WriteL(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC8& aValue);
1.72 +
1.73 + // new 16-bit descriptor variants
1.74 + static TInt Read(const RMmfIpcMessage& aMessage, TInt aParam, TDes16& aResult);
1.75 + static TInt Write(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC16& aValue);
1.76 + static void ReadL(const RMmfIpcMessage& aMessage, TInt aParam, TDes16& aResult);
1.77 + static void WriteL(const RMmfIpcMessage& aMessage, TInt aParam, const TDesC16& aValue);
1.78 + };
1.79 +
1.80 +#include <testframeworkipc.inl>
1.81 +
1.82 +#endif // __TESTFRAMEWORKIPC_H__