bluetoothapitest/bluetoothsvs/T_BTUserAPI/inc/T_RfcommRemotePortParamsData.h
changeset 0 29b1cd4cb562
equal deleted inserted replaced
-1:000000000000 0:29b1cd4cb562
       
     1 /*
       
     2 * Copyright (c) 2005-2009 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 #if (!defined __T_RFCOMM_REMOTE_PORT_PARAMS__DATA_H__)
       
    20 #define __T_RFCOMM_REMOTE_PORT_PARAMS__DATA_H__
       
    21 	
       
    22 // User Includes
       
    23 #include "DataWrapperBase.h"
       
    24 
       
    25 // EPOC includes
       
    26 #include <bt_sock.h>
       
    27 
       
    28 /**
       
    29  * Test RF COMM remote port parameters class
       
    30  *
       
    31  */
       
    32 class CT_RfcommRemotePortParamsData : public CDataWrapperBase
       
    33 	{
       
    34 public:
       
    35 	/**
       
    36 	* Public destructor
       
    37 	*/
       
    38 	~CT_RfcommRemotePortParamsData();
       
    39 	
       
    40 	/**
       
    41 	* Two phase constructor
       
    42 	*/
       
    43 	static CT_RfcommRemotePortParamsData*	NewL();
       
    44 
       
    45 	/**
       
    46 	* Process a command read from the ini file
       
    47 	*
       
    48 	* @param aCommand			The command to process
       
    49 	* @param aSection			The section in the ini containing data for the command
       
    50 	* @param aAsyncErrorIndex	Command index for async calls to return errors to
       
    51 	*
       
    52 	* @return					ETrue if the command is processed
       
    53 	*
       
    54 	* @leave					System wide error
       
    55 	*/
       
    56 	virtual TBool	DoCommandL(const TTEFFunction& aCommand, const TTEFSectionName& aSection, const TInt aAsyncErrorIndex);
       
    57 
       
    58 	/**
       
    59 	* Return a pointer to the object that the data wraps
       
    60 	*
       
    61 	* @return	pointer to the object that the data wraps
       
    62 	*/
       
    63 	virtual TAny*	GetObject();
       
    64 
       
    65 	/**
       
    66 	* Set the object that the data wraps
       
    67 	*
       
    68 	* @param	aObject object that the wrapper is testing
       
    69 	*
       
    70 	* @leave	KErrNotSupported if the the function is not supported
       
    71 	*/
       
    72 	virtual void	SetObjectL(TAny* aObject);
       
    73 
       
    74 	/**
       
    75 	* The object will no longer be owned by this
       
    76 	*
       
    77 	* @leave	KErrNotSupported if the the function is not supported
       
    78 	*/
       
    79 	virtual void	DisownObjectL();
       
    80 
       
    81 	inline virtual TCleanupOperation CleanupOperation();
       
    82 
       
    83 protected:
       
    84 	CT_RfcommRemotePortParamsData();
       
    85 	void ConstructL();
       
    86 
       
    87 private:
       
    88 	void DestroyData();
       
    89 	
       
    90 	inline void	DoCmdTRfcommRemotePortParams();
       
    91 	inline void	DoCmdIsValid(const TDesC& aSection);
       
    92 	
       
    93 	inline void DoCmdGetXOnChar(const TDesC& aSection);
       
    94 	inline void	DoCmdSetXOnChar(const TDesC& aSection);
       
    95 	inline void DoCmdGetXOffChar(const TDesC& aSection);
       
    96 	inline void DoCmdSetXOffChar(const TDesC& aSection);
       
    97 	
       
    98 	inline void	DoCmdGetFlowCtrl(const TDesC& aSection);
       
    99 	inline void	DoCmdSetFlowCtrl(const TDesC& aSection);
       
   100 
       
   101 	inline void	DoCmdUpdateFlowCtrlBit(const TDesC& aSection);
       
   102 	inline void DoCmdUpdateWholeFlowCtrl(const TDesC& aSection);
       
   103 
       
   104 	inline void	DoCmdGetBitRate(const TDesC& aSection);
       
   105 	inline void	DoCmdSetBitRate(const TDesC& aSection);
       
   106 	
       
   107 	inline void	DoCmdGetDataBits(const TDesC& aSection);
       
   108 	inline void	DoCmdSetDataBits(const TDesC& aSection);
       
   109 	
       
   110 	inline void	DoCmdGetStopBit(const TDesC& aSection);
       
   111 	inline void	DoCmdSetStopBit(const TDesC& aSection);
       
   112 	
       
   113 	inline void	DoCmdGetParity(const TDesC& aSection);
       
   114 	inline void	DoCmdSetParity(const TDesC& aSection);
       
   115 
       
   116 	inline void	DoCmdUpdateFromRPNTransaction(const TDesC& aSection);
       
   117 	
       
   118 	static void CleanupOperation(TAny* aAny);
       
   119 
       
   120 private:
       
   121 	TRfcommRemotePortParams* iData;
       
   122 	};
       
   123 
       
   124 #endif /* __T_RFCOMM_REMOTE_PORT_PARAMS__DATA_H__*/