bluetoothapitest/bluetoothsvs/T_BTUserAPI/inc/T_AvdtpMediaTransportCapabilitiesData.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_AVDTP_MEDIATRANSPORT_CAPABILITIES_DATA_H__)
       
    20 #define __T_AVDTP_MEDIATRANSPORT_CAPABILITIES_DATA_H__
       
    21 
       
    22 
       
    23 
       
    24 class TAvdtpServiceCapability;
       
    25 
       
    26 /**
       
    27  * Test Representing the Media Transport Capability of AVDTP
       
    28  *
       
    29  */
       
    30 class CT_AvdtpMediaTransportCapabilitiesData :
       
    31 	public CT_AvdtpServiceCapabilityData
       
    32 	{
       
    33 public:
       
    34 	/**
       
    35 	 * Two phase constructor
       
    36 	 */
       
    37 	static CT_AvdtpMediaTransportCapabilitiesData* NewL();
       
    38 
       
    39 	/**
       
    40 	 * Public destructor
       
    41 	 */
       
    42 	~CT_AvdtpMediaTransportCapabilitiesData();
       
    43 
       
    44 	/**
       
    45 	 * Process a command read from the ini file
       
    46 	 *
       
    47 	 * @param aCommand			The command to process
       
    48 	 * @param aSection			The section in the ini containing data for the command
       
    49 	 * @param aAsyncErrorIndex	Command index for async calls to return errors to
       
    50 	 *
       
    51 	 * @return					ETrue if the command is processed
       
    52 	 *
       
    53 	 * @leave					System wide error
       
    54 	 */
       
    55 	virtual TBool DoCommandL(const TTEFFunction& aCommand,
       
    56 			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 		return iAvdtpMediaTransportCapabilities;
       
    66 		}
       
    67 
       
    68 	/**
       
    69 	 * Set the object that the data wraps
       
    70 	 *
       
    71 	 * @param	aObject object that the wrapper is testing
       
    72 	 *
       
    73 	 */
       
    74 	virtual void SetObjectL(TAny* aAny);
       
    75 
       
    76 	/**
       
    77 	 * The object will no longer be owned by this
       
    78 	 *
       
    79 	 * @leave	KErrNotSupported if the the function is not supported
       
    80 	 */
       
    81 	virtual void DisownObjectL();
       
    82 
       
    83 protected:
       
    84 	/**
       
    85 	 * Protected constructor. First phase construction
       
    86 	 */
       
    87 	CT_AvdtpMediaTransportCapabilitiesData();
       
    88 
       
    89 	virtual TAvdtpServiceCapability* GetAvdtpServiceCapability() const;
       
    90 
       
    91 	/**
       
    92 	 * Second phase construction
       
    93 	 */
       
    94 	void ConstructL();
       
    95 
       
    96 private:
       
    97 	/**
       
    98 	 * Helper methods
       
    99 	 */
       
   100 	void DestroyData();
       
   101 
       
   102 	inline void DoCmdnewL();
       
   103 
       
   104 private:
       
   105 	TAvdtpMediaTransportCapabilities* iAvdtpMediaTransportCapabilities;
       
   106 	};
       
   107 
       
   108 #endif /* __T_AVDTP_MEDIATRANSPORT_CAPABILITIES_DATA_H__ */