mtpfws/mtpfw/datatypes/interface/mtpdatatypeconstants.h
changeset 0 d0791faffa3f
child 4 60a94a45d437
equal deleted inserted replaced
-1:000000000000 0:d0791faffa3f
       
     1 // Copyright (c) 2006-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  @publishedPartner
       
    19  @released
       
    20 */
       
    21 
       
    22 #ifndef MTPDATATYPECONSTANTS_H
       
    23 #define MTPDATATYPECONSTANTS_H
       
    24 
       
    25 #include <e32def.h>
       
    26 
       
    27 /**
       
    28 The MTP datatype codes.
       
    29 @publishedPartner
       
    30 @released  
       
    31 */
       
    32 enum TMTPTypeIds
       
    33     {
       
    34     EMTPFirstLibraryDataType                        = 0x00000000,
       
    35     
       
    36     EMTPTypeUndefined                               = EMTPFirstLibraryDataType,
       
    37     
       
    38     EMTPTypeFirstSimpleType                         = 0x00000001,
       
    39     EMTPTypeINT8                                    = EMTPTypeFirstSimpleType,
       
    40     EMTPTypeUINT8                                   = 0x00000002,
       
    41     EMTPTypeINT16                                   = 0x00000003,
       
    42     EMTPTypeUINT16                                  = 0x00000004,
       
    43     EMTPTypeINT32                                   = 0x00000005,
       
    44     EMTPTypeUINT32                                  = 0x00000006,
       
    45     EMTPTypeINT64                                   = 0x00000007,
       
    46     EMTPTypeUINT64                                  = 0x00000008,
       
    47     EMTPTypeINT128                                  = 0x00000009,
       
    48     EMTPTypeUINT128                                 = 0x0000000A,
       
    49     EMTPTypeLastSimpleType                          = EMTPTypeUINT128,
       
    50     
       
    51     EMTPTypeFirstSimpleArrayType                    = 0x00004001,
       
    52     EMTPTypeAINT8                                   = EMTPTypeFirstSimpleArrayType,
       
    53     EMTPTypeAUINT8                                  = 0x00004002,
       
    54     EMTPTypeAINT16                                  = 0x00004003,
       
    55     EMTPTypeAUINT16                                 = 0x00004004,
       
    56     EMTPTypeAINT32                                  = 0x00004005,
       
    57     EMTPTypeAUINT32                                 = 0x00004006,
       
    58     EMTPTypeAINT64                                  = 0x00004007,
       
    59     EMTPTypeAUINT64                                 = 0x00004008,
       
    60     EMTPTypeAINT128                                 = 0x00004009,
       
    61     EMTPTypeAUINT128                                = 0x0000400A,
       
    62     EMTPTypeLastSimpleArrayType                     = EMTPTypeAUINT128,
       
    63     
       
    64     EMTPTypeFirstComplexType                        = 0x0000FFFF,
       
    65     EMTPTypeString                                  = EMTPTypeFirstComplexType,
       
    66     EMTPTypeArray                                   = 0x00010001,
       
    67     EMTPTypeFile                                    = 0x00010002,
       
    68     EMTPTypeOpaqueData								= 0x00010003,
       
    69     EMTPTypeTrivialData                             = 0x00010004,
       
    70     EMTPTypeLastComplexType                         = EMTPTypeTrivialData,
       
    71     
       
    72     EMTPTypeFirstCompoundType                       = 0x00020000,
       
    73     EMTPTypeCompound                                = EMTPTypeFirstCompoundType,
       
    74     EMTPTypeDeviceInfoDataset                       = 0x00020100,
       
    75     EMTPTypeDevicePropDescDataset                   = 0x00020200,
       
    76     EMTPTypeDevicePropDescEnumerationFormDataset    = 0x00020201,
       
    77     EMTPTypeDevicePropDescRangeFormDataset          = 0x00020202,
       
    78     EMTPTypeInterdependentPropDescDataset           = 0x00020300,
       
    79     EMTPTypeInterdependentPropDescElementDataset    = 0x00020301,
       
    80     EMTPTypeObjectInfoDataset                       = 0x00020400,
       
    81     EMTPTypeObjectPropDescDataset                   = 0x00020500,
       
    82     EMTPTypeObjectPropDescEnumerationFormDataset    = 0x00020501,
       
    83     EMTPTypeObjectPropDescRangeFormDataset          = 0x00020502,
       
    84 	EMTPTypeServiceObjPropExtnFormDataset			= 0x00020504,
       
    85 	EMTPTypeServiceMethodParamExtnFormDataset		= 0x00020505,
       
    86     EMTPTypeObjectPropListDataset                   = 0x00020600,
       
    87     EMTPTypeServicePropListDataset                  = EMTPTypeObjectPropListDataset,
       
    88     EMTPTypeObjectPropListElementDataset            = 0x00020601,
       
    89     EMTPTypeServicePropListElementDataset           = EMTPTypeObjectPropListElementDataset,
       
    90     EMTPTypeStorageInfoDataset                      = 0x00020700,
       
    91     EMTPTypeServiceInfoDataset						= 0x00020800,
       
    92 	EMTPTypeServiceFormatElementDataset				= 0x00020801,
       
    93 	EMTPTypeServiceFormatListDataset				= 0x00020802,
       
    94 	EMTPTypeServicePropertyElementDataset			= 0x00020803,
       
    95 	EMTPTypeServicePropertyListDataset					= 0x00020804,
       
    96 	EMTPTypeServiceMethodElementDataset				= 0x00020805,
       
    97 	EMTPTypeServiceMethodListDataset				= 0x00020806,
       
    98 	EMTPTypeServiceEventElementDataset				= 0x00020807,
       
    99 	EMTPTypeServiceEventListDataset					= 0x00020808,
       
   100 	EMTPTypeServiceSectionDataset					= 0x20020809,
       
   101 	EMTPTypeServiceCapabilityListDataset			= 0x00020900,
       
   102 	EMTPTypeFormatCapabilityListDataset             = EMTPTypeServiceCapabilityListDataset,
       
   103 	EMTPTypeFormatCapabilityDataset					= 0x00020901,
       
   104 	EMTPTypeServicePropDescList						= 0x00020902,
       
   105 	EMTPTypeServicePropDesc							= 0x00020903,
       
   106 	EMTPTypeDeleteObjectPropListDataset             = 0x00020A00,
       
   107 	EMTPTypeDeleteServicePropListDataset            = 0x00020B00,
       
   108 	EMTPTypeLastCompoundType						= EMTPTypeDeleteServicePropListDataset,
       
   109     
       
   110     EMTPTypeFirstFlatType                           = 0x00040000,
       
   111     EMTPTypeFlat                                    = EMTPTypeFirstFlatType,
       
   112     EMTPTypeEventDataset                            = 0x00040001,
       
   113     EMTPTypeRequestDataset                          = 0x00040002,
       
   114     EMTPTypeResponseDataset                         = 0x00040003,
       
   115     EMTPTypeDataPair                                = 0x00040004,
       
   116     EMTPTypeLastFlatType                            = EMTPTypeDataPair,
       
   117     
       
   118     EMTPTypeReference                               = 0x000FFFFF,
       
   119     EMTPLastLibraryDataType                         = EMTPTypeReference,
       
   120 
       
   121 	/**
       
   122 	The Range for USB   transport is 0x00010000 to 0x000100FF
       
   123 	The Range for PTPIP transport is 0x00010100 to 0x000101FF
       
   124 	*/    
       
   125     EMTPFirstTransportDataType                      = 0x00010000,
       
   126     EMTPLastTransportDataType                       = 0x0001FFFF,
       
   127     
       
   128     EMTPFirstVendorExtensionDataType                = 0x80000000,
       
   129     EMTPLastVendorExtensionDataType                 = 0xFFFFFFFF,
       
   130     };
       
   131 
       
   132 /**
       
   133 The MTP INT8 data type size (in bytes).
       
   134 @publishedPartner
       
   135 @released  
       
   136 */
       
   137 const TUint KMTPTypeINT8Size(1);
       
   138 
       
   139 /**
       
   140 The MTP UINT8 data type size (in bytes).
       
   141 @publishedPartner
       
   142 @released  
       
   143 */
       
   144 const TUint KMTPTypeUINT8Size(1);
       
   145 
       
   146 /**
       
   147 The MTP INT16 data type size (in bytes).
       
   148 @publishedPartner
       
   149 @released  
       
   150 */
       
   151 const TUint KMTPTypeINT16Size(2);
       
   152 
       
   153 /**
       
   154 The MTP UINT16 data type size (in bytes).
       
   155 @publishedPartner
       
   156 @released  
       
   157 */
       
   158 const TUint KMTPTypeUINT16Size(2);
       
   159 
       
   160 /**
       
   161 The MTP INT32 data type size (in bytes).
       
   162 @publishedPartner
       
   163 @released  
       
   164 */
       
   165 const TUint KMTPTypeINT32Size(4);
       
   166 
       
   167 /**
       
   168 The MTP UINT32 data type size (in bytes).
       
   169 @publishedPartner
       
   170 @released  
       
   171 */
       
   172 const TUint KMTPTypeUINT32Size(4);
       
   173 
       
   174 /**
       
   175 The MTP INT64 data type size (in bytes).
       
   176 @publishedPartner
       
   177 @released  
       
   178 */
       
   179 const TUint KMTPTypeINT64Size(8);
       
   180 
       
   181 /**
       
   182 The MTP UINT64 data type size (in bytes).
       
   183 @publishedPartner
       
   184 @released  
       
   185 */
       
   186 const TUint KMTPTypeUINT64Size(8);
       
   187 
       
   188 /**
       
   189 The MTP INT128 data type size (in bytes).
       
   190 @publishedPartner
       
   191 @released  
       
   192 */
       
   193 const TUint KMTPTypeINT128Size(16);
       
   194 
       
   195 /**
       
   196 The MTP UINT128 data type size (in bytes).
       
   197 @publishedPartner
       
   198 @released  
       
   199 */
       
   200 const TUint KMTPTypeUINT128Size(16);
       
   201 
       
   202 /**
       
   203 The MTP String data type character size (in bytes).
       
   204 @publishedPartner
       
   205 @released  
       
   206 */
       
   207 const TUint     KMTPCharSize(sizeof(TUint16));
       
   208 
       
   209 /**
       
   210 The MTP String data type null character.
       
   211 @publishedPartner
       
   212 @released  
       
   213 */
       
   214 const TUint16   KMTPNullChar(0);
       
   215 
       
   216 /**
       
   217 The MTP String data type null character length.
       
   218 @publishedPartner
       
   219 @released  
       
   220 */
       
   221 const TUint     KMTPNullCharLen(sizeof(KMTPNullChar) / KMTPCharSize);
       
   222 
       
   223 /**
       
   224 The MTP String data type absolute maximum length.
       
   225 @publishedPartner
       
   226 @released  
       
   227 */
       
   228 const TUint     KMTPMaxStringLength(255);
       
   229 
       
   230 /**
       
   231 The MTP String data type maximum character content length.
       
   232 @publishedPartner
       
   233 @released  
       
   234 */
       
   235 const TUint     KMTPMaxStringCharactersLength(KMTPMaxStringLength - KMTPNullCharLen);
       
   236 
       
   237 #endif // MTPDATATYPECONSTANTS_H
       
   238 
       
   239