bluetooth/btstack/avctp/common/avctpcommon.h
changeset 0 29b1cd4cb562
equal deleted inserted replaced
-1:000000000000 0:29b1cd4cb562
       
     1 // Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 /**
       
    17  @file
       
    18  @internalTechnology
       
    19 */
       
    20 
       
    21 #ifndef AVCTPCOMMON_H
       
    22 #define AVCTPCOMMON_H
       
    23 
       
    24 #include <bt_sock.h>
       
    25 #include <remcon/remconserverid.h>
       
    26 #include <bluetoothav.h>
       
    27 #include <es_prot.h>
       
    28 #include <bluetooth/avctptypes.h>
       
    29 
       
    30 namespace SymbianAvctp
       
    31 	{
       
    32 
       
    33 	const TUint32 KDefaultSidforPids =  KRemConSrvTUint;
       
    34 	
       
    35 	const TInt KAvctpPrimaryChannel = 0;
       
    36 	const TInt KAvctpSecondaryChannel = 1;
       
    37 	const TInt KAvctpInvalidChannel = KMaxTInt;
       
    38 	
       
    39 	enum TControlIoctls
       
    40 		{
       
    41 		// commands from client to server
       
    42 		EUndefinedIoctl = 0,
       
    43 		EPrimaryChannelAttachToTransport = 1,
       
    44 		ESecondaryChannelAttachToTransport = 2,
       
    45 		EAwaitExtendedTransport = 3,
       
    46 		EAwaitProvidedTransport = 4,
       
    47 		EPrimaryChannelDetachFromTransport = 5,
       
    48 		ESecondaryChannelDetachFromTransport = 6,
       
    49 		EPrimaryChannelRefuseAttach = 7,
       
    50 		ESecondaryChannelRefuseAttach = 8,
       
    51 		EPrimaryChannelAgreeAttachment = 9,
       
    52 		ESecondaryChannelAgreeAttachment = 10,
       
    53 		// events from server to client
       
    54 		EAttachIndicate = 11,
       
    55 		EAttachConfirm = 12,
       
    56 		EDetachConfirm = 13,
       
    57 		EDetachIndicate = 14,
       
    58 		ELinkUp = 15,
       
    59 		ELinkDown = 16,
       
    60 		EError = 17,
       
    61 		};
       
    62 
       
    63 	enum TSocketOpts
       
    64 		{
       
    65 		};
       
    66 	}
       
    67 
       
    68 NONSHARABLE_CLASS(TControlIoctlMessage)
       
    69 	{
       
    70 public:
       
    71 	TControlIoctlMessage() : 
       
    72 		iIoctl(SymbianAvctp::EUndefinedIoctl),
       
    73 		iAddr(0)
       
    74 		{
       
    75 		}
       
    76 	TControlIoctlMessage(SymbianAvctp::TControlIoctls aIoctl, const TBTDevAddr& aAddr, TInt aError = KErrNone) :
       
    77 		iIoctl(aIoctl),
       
    78 		iError(aError)
       
    79 		{
       
    80 		iAddr.SetBTAddr(aAddr);
       
    81 		}
       
    82 public:
       
    83 	SymbianAvctp::TControlIoctls	iIoctl;
       
    84 	TAvctpSockAddr					iAddr;
       
    85 	TInt							iError;
       
    86 	};
       
    87 
       
    88 NONSHARABLE_CLASS(TOptionMessage)
       
    89 	{
       
    90 public:
       
    91 	TBTDevAddr	iAddr;
       
    92 	TInt		iMtu;
       
    93 	};
       
    94 
       
    95 #endif
       
    96 // AVCTPCOMMON_H 
       
    97