epoc32/include/sensrvproperty.h
branchSymbian2
changeset 2 2fe1408b6811
parent 0 061f57f2323e
child 4 837f303aceeb
     1.1 --- a/epoc32/include/sensrvproperty.h	Tue Nov 24 13:55:44 2009 +0000
     1.2 +++ b/epoc32/include/sensrvproperty.h	Tue Mar 16 16:12:26 2010 +0000
     1.3 @@ -1,1 +1,670 @@
     1.4 -sensrvproperty.h
     1.5 +/*
     1.6 +* Copyright (c) 2008 Nokia Corporation and/or its subsidiary(-ies). 
     1.7 +* All rights reserved.
     1.8 +* This component and the accompanying materials are made available
     1.9 +* under the terms of the License "Symbian Foundation License v1.0" to Symbian Foundation members and "Symbian Foundation End User License Agreement v1.0" to non-members
    1.10 +* which accompanies this distribution, and is available
    1.11 +* at the URL "http://www.symbianfoundation.org/legal/licencesv10.html".
    1.12 +*
    1.13 +* Initial Contributors:
    1.14 +* Nokia Corporation - initial contribution.
    1.15 +*
    1.16 +* Contributors:
    1.17 +*
    1.18 +* Description:  Sensor and channel property container
    1.19 +*
    1.20 +*/
    1.21 +
    1.22 +
    1.23 +#ifndef SENSRVPROPERTY_H
    1.24 +#define SENSRVPROPERTY_H
    1.25 +
    1.26 +//  INCLUDES
    1.27 +#include <e32base.h>
    1.28 +#include <babitflags.h>
    1.29 +
    1.30 +// CONSTANTS
    1.31 +
    1.32 +/**
    1.33 +* Maximum size of the buffer when the property type is ESensrvBufferProperty
    1.34 +* @see TSensrvProperty
    1.35 +*/
    1.36 +const TInt KSensrvPropertyTextBufferSize = 20;
    1.37 +
    1.38 +
    1.39 +// DATA TYPES
    1.40 +
    1.41 +/**
    1.42 +* Property types
    1.43 +* @see TSensrvProperty
    1.44 +*/
    1.45 +enum TSensrvPropertyType
    1.46 +    {
    1.47 +    /** Default property type */
    1.48 +    ESensrvUninitializedProperty = 0,
    1.49 +    /** Integer property type. TInt is used to store property value */
    1.50 +    ESensrvIntProperty,
    1.51 +    /** Real property type. TReal is used to store property value */
    1.52 +    ESensrvRealProperty,
    1.53 +    /**
    1.54 +    Descriptor property type. TBuf<KSensrvPropertyTextBufferSize> is used to store
    1.55 +    property value
    1.56 +    */
    1.57 +    ESensrvBufferProperty
    1.58 +    };
    1.59 +
    1.60 +/**
    1.61 +* Special index types for iArrayIndex.  Any other value indicates that this property is a member of
    1.62 +* an array of properties
    1.63 +* @see TSensrvProperty
    1.64 +*/
    1.65 +enum TSensrvArrayIndex
    1.66 +    {
    1.67 +    /** This property is a single property and is not a member of an array of properties */
    1.68 +    ESensrvSingleProperty    = -1,
    1.69 +    /**
    1.70 +    This property is the information item for an array of properties. iIntValueMin and iIntValueMax
    1.71 +    values in a property of this type defines the range of the property array
    1.72 +    */
    1.73 +    ESensrvArrayPropertyInfo = -2
    1.74 +    };
    1.75 +
    1.76 +/**
    1.77 +* Identifies the range of values that must be used for TSensrvPropertyId. These ranges are defined so that
    1.78 +* any customers wishing to add additional properties not yet supported by Symbian can do so without
    1.79 +* causing clashes with Symbian defined properties. 
    1.80 +* 1-4095      General channel properties owned and defined by Symbian
    1.81 +* 4096-8191   Specific Channel properties owned and defined by Symbian
    1.82 +* 8192-12287  A range for customers to define their own properties. Usage defined by customer
    1.83 +* @see TSensrvPropertyId
    1.84 +* @see TSensrvProperty
    1.85 +*/
    1.86 +enum TSensrvPropertyRangeUsage
    1.87 +    {
    1.88 +    // General properties
    1.89 +    ESensrvPropertyRangeNotDefined = 0, // 0x0000
    1.90 +    ESensrvGeneralPropertyRangeBase = 1, // 0x0001
    1.91 +    ESensrvGeneralPropertyRangeEnd = 4095, // 0x0FFF
    1.92 +
    1.93 +    // Channel properties
    1.94 +    ESensrvChannelPropertyRangeBase = 4096, // 0x1000
    1.95 +    ESensrvChannelPropertyRangeEnd = 8191, // 0x1FFF
    1.96 +
    1.97 +    // A range for licensees to define their own properties. Usage is defined by the licensee. 
    1.98 +    ESensrvLicenseePropertyRangeBase = 8192, // 0x2000
    1.99 +    ESensrvLicenseePropertyRangeEnd = 12287 // 0x2FFF
   1.100 +    };
   1.101 +
   1.102 +/**
   1.103 +* Type definition for property identifier.
   1.104 +* @see TSensrvProperty
   1.105 +*/
   1.106 +typedef TUint32 TSensrvPropertyId;
   1.107 +
   1.108 +// CLASS DECLARATION
   1.109 +
   1.110 +/**
   1.111 +* TSensrvProperty is a simple data class that contains sensor channel property information. The class has
   1.112 +* little behaviour and only does sanity checks where it is possible. It is therefore assumed that users of
   1.113 +* this class are aware of and conform to a properties definition for a given property identifier.
   1.114 +* 
   1.115 +* There are 2 groups of properties, General Channel Properties and Specific Channel Properties.
   1.116 +* 
   1.117 +* General Channel Properties are properties that are supported by all channels. These are defined in 
   1.118 +* sensrvgeneralproperties.h. Specific Channel Properties are properties that are supported by specific 
   1.119 +* channel types as required. These are defined in the relevant headers files.
   1.120 +* 
   1.121 +* The property identifier uniquely identifies the property within a channel. These property ids must fall
   1.122 +* into the relevant range specified by TSensrvPropertyRangeUsage. Each property will have a constant 
   1.123 +* defined for its identifier. e.g. KSensrvPropIdDataRate.
   1.124 +* 
   1.125 +* @see TSensrvProperty::SetPropertyId()
   1.126 +* @see TSensrvProperty::GetPropertyId()
   1.127 +* @see TSensrvPropertyRangeUsage
   1.128 +* @see KSensrvPropIdDataRate
   1.129 +* 
   1.130 +* The property type is used to determine whether the property is TInt, TReal or Buffer. The property type
   1.131 +* is automatically set when the value of the object is set. 
   1.132 +* 
   1.133 +* @see TSensrvPropertyType
   1.134 +* @see TSensrvProperty::PropertyType()
   1.135 +* 
   1.136 +* The value fields are used to indicate the value of a property when the property contains a single int,
   1.137 +* real or buffer value. The min and max value fields are used when a property has a range of int or real
   1.138 +* values. A property cannot have a range of buffer values. The value and min/max values of a property
   1.139 +* will never be set at the same time.
   1.140 +* 
   1.141 +* @see TSensrvProperty::GetValue()
   1.142 +* @see TSensrvProperty::SetValue()
   1.143 +* @see TSensrvProperty::GetValueRef()
   1.144 +* @see TSensrvProperty::GetMinValue()
   1.145 +* @see TSensrvProperty::SetMinValue()
   1.146 +* @see TSensrvProperty::GetMaxValue()
   1.147 +* @see TSensrvProperty::SetMaxValue()
   1.148 +* 
   1.149 +* Properties can be read only which means it cannot be set by CSensrvChannel::SetPropertyL().
   1.150 +* 
   1.151 +* @see TSensrvProperty::ReadOnly()
   1.152 +* @see TSensrvProperty::SetReadOnly()
   1.153 +* @see CSensrvChannel
   1.154 +* 
   1.155 +* Properties can either be single properties, or can be a member of an array of properties. The array
   1.156 +* index field is set to ESensrvSingleProperty(-1) if the property is single. If a property is part of an
   1.157 +* array then the array index field will be set to ESensrvArrayPropertyInfo(-2) or the index for the array.
   1.158 +* When the array index is ESensrvArrayPropertyInfo the property uses the iIntValueMin and iIntValueMax fields
   1.159 +* to indicate the range of the array. When the array index is an actual index (neither ESensrvArrayPropertyInfo
   1.160 +* nor ESensrvArrayPropertyInfo) the property contains data.
   1.161 +* 
   1.162 +* Example:
   1.163 +* 
   1.164 +* A Sensor channel which supports data rates within a given range can use one Data Rate
   1.165 +* property. The range is defined using the property's maximum and minimum value. E.g. A
   1.166 +* sensor channel supports a data range from 10Hz to 100Hz and all values within this range
   1.167 +* are feasible. To implement this use one Data Rate property with a minimum value 10 and a
   1.168 +* maximum value of 100.
   1.169 +* 
   1.170 +* A Sensor channel which supports discrete data rates can use the Data Rate property as
   1.171 +* an array. E.g. A sensor channel supports the following data rates 10Hz, 40Hz and 50Hz.
   1.172 +* To implement this four different Data Rate properties are needed. The following table
   1.173 +* shows the content of the four properties, only mandatory attributes are shown.
   1.174 +*  
   1.175 +* @code
   1.176 +* property ID     Array index     Value           Min Value       Max Value       Read only
   1.177 +* -----------     -----------     -----           ---------       ---------       ---------
   1.178 +* 0x00000002      -2              1               0               2               EFalse
   1.179 +* 0x00000002      0               10              n/a             n/a             ETrue
   1.180 +* 0x00000002      1               40              n/a             n/a             ETrue
   1.181 +* 0x00000002      2               50              n/a             n/a             ETrue
   1.182 +* @endcode
   1.183 +* 
   1.184 +* The first property (first row in table above) is the header for the property array. It
   1.185 +* defines that this property is an array property. The attributes of this property are:
   1.186 +* 
   1.187 +* Array index:
   1.188 +* -2 means that the property is an array property
   1.189 +* Value:
   1.190 +* 1 means that current value of the property is defined by the property with an array index of 
   1.191 +* 1. The value is 40Hz in this example.
   1.192 +* Min value 
   1.193 +* 0 is the start index of the property array 
   1.194 +* Max value:
   1.195 +* 2 is the last index of the property array
   1.196 +* Read only:
   1.197 +* EFalse means that the properties current value can be changed,
   1.198 +* 
   1.199 +* In this example the possible values of the property are 0, 1, and 2 which corresponds to data
   1.200 +* rates of 10Hz, 40Hz and 50Hz.
   1.201 +* 
   1.202 +* @see TSensrvArrayIndex
   1.203 +* @see TSensrvProperty::SetArrayIndex()
   1.204 +* @see TSensrvProperty::GetArraIndex()
   1.205 +* 
   1.206 +* The property item index is used to identify a specific item in the channel data structure that the property
   1.207 +* refers to. For example the Accelerometer XYZ-axis data structure defines data for the x, y and Z axis.
   1.208 +* Individual properties could have been defined for each of these axis. Instead a single property is defined
   1.209 +* and the Item Index is used to identify the relevant axis in the channel data structure that the property
   1.210 +* applies to. The indexes for these specific items and the channel data structures themselves are defined in
   1.211 +* the sensor specific headers files found in epoc32\include\sensors\channels.
   1.212 +* 
   1.213 +* Example:
   1.214 +* 
   1.215 +* Accelerometer data definition. TSensrvAccelerometerAxisDataIndexes is used to provide an index that
   1.216 +* relates to each of the class fields.
   1.217 +* 
   1.218 +* @code
   1.219 +* // ACCELEROMETER RELATED DATATYPES
   1.220 +* 
   1.221 +* // Accelerometer axis data type
   1.222 +* 
   1.223 +* class TSensrvAccelerometerAxisData 
   1.224 +*     {
   1.225 +* public:
   1.226 +*     //
   1.227 +*     // Channel data type Id number
   1.228 +*     //      
   1.229 +*     static const TSensrvChannelDataTypeId KDataTypeId = 0x1020507E;
   1.230 +* 
   1.231 +*     //
   1.232 +*     // Channel data type index numbers
   1.233 +*     //
   1.234 +* 	enum TSensrvAccelerometerAxisDataIndexes
   1.235 +*           {
   1.236 +*            ETimeStamp = 0,
   1.237 +*            EAxisX,
   1.238 +*            EAxisY,
   1.239 +*            EAxisZ
   1.240 +*           }; 
   1.241 +* public:
   1.242 +*     //
   1.243 +*     // - Item name:   Sampling time.
   1.244 +*     // - Item Index:  0
   1.245 +*     // - Conditions:  None
   1.246 +*     // - Description: Timestamp for a sample.
   1.247 +*     //   
   1.248 +*     TTime iTimeStamp;    
   1.249 +* 
   1.250 +*     //
   1.251 +*     // - Item name:   Accelerometer x-axis 
   1.252 +*     // - Item Index:  1
   1.253 +*     // - Conditions:  Single limit and range 
   1.254 +*     // - Description: Accelerometer values from x-axis 
   1.255 +*     //
   1.256 +*     TInt iAxisX;  
   1.257 +* 
   1.258 +*     //
   1.259 +*     // - Item name:   Accelerometer y-axis 
   1.260 +*     // - Item Index:  2
   1.261 +*     // - Conditions:  Single limit and range 
   1.262 +*     // - Description: Accelerometer values from y-axis 
   1.263 +*     // 
   1.264 +*     TInt iAxisY;  
   1.265 +* 
   1.266 +*     //
   1.267 +*     // - Item name:   Accelerometer z-axis 
   1.268 +*     // - Item Index:  3
   1.269 +*     // - Conditions:  Single limit and range 
   1.270 +*     // - Description: Accelerometer values from z-axis 
   1.271 +*     //
   1.272 +*     TInt iAxisZ;  
   1.273 +*     };
   1.274 +* @endcode
   1.275 +* 
   1.276 +* @see TSensrvProperty::SetItemIndex()
   1.277 +* @see TSensrvProperty::PropertyItemIndex()
   1.278 +* @lib sensrvutil.lib
   1.279 +* @since S60 5.0
   1.280 +*/
   1.281 +NONSHARABLE_CLASS( TSensrvProperty )
   1.282 +    {
   1.283 +public:
   1.284 +
   1.285 +    /**
   1.286 +    Default Constructor
   1.287 +    */
   1.288 +    IMPORT_C TSensrvProperty();
   1.289 +
   1.290 +    /**
   1.291 +    * Constructor to create complete integer type property.
   1.292 +    * 
   1.293 +    * @since S60 5.0
   1.294 +    * @param  aPropertyId Id of the property
   1.295 +    * @param  aItemIndex Item index of the property. Mapped to a specific item in channel data structure.
   1.296 +    * @param  aValue Value of the property.
   1.297 +    * @param  aMaxValue Maximum value of the property
   1.298 +    * @param  aMinValue Minimum value of the property
   1.299 +    * @param  aReadOnly Readonly-flag of the property
   1.300 +    * @param  aPropertyType Type of the property
   1.301 +    */
   1.302 +    IMPORT_C TSensrvProperty( const TSensrvPropertyId aPropertyId,
   1.303 +                              const TInt aItemIndex,
   1.304 +                              const TInt aValue,
   1.305 +                              const TInt aMaxValue,
   1.306 +                              const TInt aMinValue,
   1.307 +                              const TBool aReadOnly,
   1.308 +                              const TSensrvPropertyType aPropertyType );
   1.309 +
   1.310 +    /**
   1.311 +    * Constructor to create property object for setting integer property value.
   1.312 +    * 
   1.313 +    * @since S60 5.0
   1.314 +    * @param  aPropertyId Id of the property
   1.315 +    * @param  aItemIndex Item index of the property. Mapped to a specific item in channel data structure.
   1.316 +    * @param  aValue Value of the property.
   1.317 +    */
   1.318 +    IMPORT_C TSensrvProperty( const TSensrvPropertyId aPropertyId,
   1.319 +                              const TInt aItemIndex,
   1.320 +                              const TInt aValue );
   1.321 +
   1.322 +    /**
   1.323 +    * Constructor to create complete TReal type of property.
   1.324 +    *
   1.325 +    * @since S60 5.0
   1.326 +    * @param  aPropertyId Id of the property
   1.327 +    * @param  aItemIndex Item index of the property. Mapped to a specific item in channel data structure.
   1.328 +    * @param  aValue Value of the property.
   1.329 +    * @param  aMaxValue Maximum value of the property
   1.330 +    * @param  aMinValue Minimum value of the property
   1.331 +    * @param  aReadOnly Readonly-flag of the property
   1.332 +    * @param  aPropertyType Type of the property
   1.333 +    */
   1.334 +    IMPORT_C TSensrvProperty( const TSensrvPropertyId aPropertyId,
   1.335 +                              const TInt aItemIndex,
   1.336 +                              const TReal aValue,
   1.337 +                              const TReal aMaxValue,
   1.338 +                              const TReal aMinValue,
   1.339 +                              const TBool aReadOnly,
   1.340 +                              const TSensrvPropertyType aPropertyType );
   1.341 +
   1.342 +    /**
   1.343 +    * Constructor to create property object for setting real property value.
   1.344 +    * 
   1.345 +    * @since S60 5.0
   1.346 +    * @param  aPropertyId Id of the property
   1.347 +    * @param  aItemIndex Item index of the property. Mapped to a specific item in channel data structure.
   1.348 +    * @param  aValue Value of the property.
   1.349 +    */
   1.350 +    IMPORT_C TSensrvProperty( const TSensrvPropertyId aPropertyId,
   1.351 +                              const TInt aItemIndex,
   1.352 +                              const TReal aValue );
   1.353 +
   1.354 +    /**
   1.355 +    * Constructor to create complete buffer property.
   1.356 +    * 
   1.357 +    * @since S60 5.0
   1.358 +    * @param  aPropertyId Id of the property
   1.359 +    * @param  aItemIndex Item index of the property. Mapped to a specific item in channel data structure.
   1.360 +    * @param  aValue Value of the property. Max length is defined in KSensrvPropertyTextBufferSize.
   1.361 +    * @param  aReadOnly Readonly-flag of the property
   1.362 +    * @param  aPropertyType Type of the property
   1.363 +    */
   1.364 +    IMPORT_C TSensrvProperty( const TSensrvPropertyId aPropertyId,
   1.365 +                              const TInt aItemIndex,
   1.366 +                              const TDesC8& aValue,
   1.367 +                              const TBool aReadOnly,
   1.368 +                              const TSensrvPropertyType aPropertyType );
   1.369 +
   1.370 +   /**
   1.371 +    * Constructor to create property object for setting buffer property value.
   1.372 +    * 
   1.373 +    * @since S60 5.0
   1.374 +    * @param  aPropertyId Id of the property
   1.375 +    * @param  aItemIndex Item index of the property. Mapped to a specific item in channel data structure.
   1.376 +    * @param  aValue Value of the property. Max length is defined in KSensrvPropertyTextBufferSize.
   1.377 +    */
   1.378 +    IMPORT_C TSensrvProperty( const TSensrvPropertyId aPropertyId,
   1.379 +                              const TInt aItemIndex,
   1.380 +                              const TDesC8& aValue );
   1.381 +
   1.382 +    /**
   1.383 +    * Set the property Id for the property.
   1.384 +    * 
   1.385 +    * @since S60 5.0
   1.386 +    * @param  aPropertyId Property Id to be set.
   1.387 +    */
   1.388 +    IMPORT_C void SetPropertyId( TSensrvPropertyId aPropertyId );
   1.389 +
   1.390 +    /**
   1.391 +    * Return Property Id
   1.392 +    * 
   1.393 +    * @since S60 5.0
   1.394 +    * @return Property Id
   1.395 +    */
   1.396 +    IMPORT_C TSensrvPropertyId GetPropertyId() const;
   1.397 +
   1.398 +    /**
   1.399 +    * Set the property item index for the property.
   1.400 +    * 
   1.401 +    * @since S60 5.0
   1.402 +    * @param  aItemIndex property item index to be set.
   1.403 +    */
   1.404 +    IMPORT_C void SetItemIndex( TInt aItemIndex );
   1.405 +
   1.406 +    /**
   1.407 +    * Get the property item index number
   1.408 +    * 
   1.409 +    * @since S60 5.0
   1.410 +    * @return Item index number.
   1.411 +    */
   1.412 +    IMPORT_C TInt PropertyItemIndex() const;
   1.413 +
   1.414 +    /**
   1.415 +    * Return property type
   1.416 +    * 
   1.417 +    * @since S60 5.0
   1.418 +    * @return Property type's Id
   1.419 +    */
   1.420 +    IMPORT_C TSensrvPropertyType PropertyType() const;
   1.421 +
   1.422 +    /**
   1.423 +    * Checks if the property is readonly
   1.424 +    *
   1.425 +    * @since S60 5.0
   1.426 +    * @return ETrue value indicates that property is a read only property.
   1.427 +    */
   1.428 +    IMPORT_C TBool ReadOnly() const;
   1.429 +
   1.430 +    /**
   1.431 +    * Set the readonly information for the property.
   1.432 +    * 
   1.433 +    * @since S60 5.0
   1.434 +    * @param  aReadOnly readonly information to be set. EFalse means that the property is not readonly.
   1.435 +    */
   1.436 +    IMPORT_C void SetReadOnly( TBool aReadOnly );
   1.437 +
   1.438 +    /**
   1.439 +    * Set integer property value
   1.440 +    * 
   1.441 +    * @since S60 5.0
   1.442 +    * @param  aValue Value to be set.
   1.443 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.444 +    * a correct type
   1.445 +    */
   1.446 +    IMPORT_C void SetValue( const TInt aValue );
   1.447 +
   1.448 +    /**
   1.449 +    * Set real property value
   1.450 +    * 
   1.451 +    * @since S60 5.0
   1.452 +    * @param  aValue Value to be set.
   1.453 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.454 +    * a correct type
   1.455 +    */
   1.456 +    IMPORT_C void SetValue( const TReal aValue );
   1.457 +
   1.458 +    /**
   1.459 +    * Set buffer property value
   1.460 +    * 
   1.461 +    * @since S60 5.0
   1.462 +    * @param  aValue Value to be set.
   1.463 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.464 +    * a correct type
   1.465 +    */
   1.466 +    IMPORT_C void SetValue( const TDesC8& aValue );
   1.467 +
   1.468 +    /**
   1.469 +    * Get integer property value
   1.470 +    * 
   1.471 +    * @since S60 5.0
   1.472 +    * @param  aValue Value to get
   1.473 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.474 +    * a correct type
   1.475 +    */
   1.476 +    IMPORT_C void GetValue( TInt& aValue ) const;
   1.477 +
   1.478 +    /**
   1.479 +    * Get real property value
   1.480 +    * 
   1.481 +    * @since S60 5.0
   1.482 +    * @param  aValue Value to get
   1.483 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.484 +    * a correct type
   1.485 +    */
   1.486 +    IMPORT_C void GetValue( TReal& aValue ) const;
   1.487 +
   1.488 +    /**
   1.489 +    * Get buffer property value
   1.490 +    * 
   1.491 +    * @since S60 5.0
   1.492 +    * @param  aValue Destination where a property value is to be copied
   1.493 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.494 +    * a correct type
   1.495 +    */
   1.496 +    IMPORT_C void GetValue( TDes8& aValue ) const;
   1.497 +
   1.498 +    /**
   1.499 +    * Get reference to buffer property value
   1.500 +    * 
   1.501 +    * @since S60 5.0
   1.502 +    * @return Reference to a property value
   1.503 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.504 +    * a correct type
   1.505 +    */
   1.506 +    IMPORT_C TDes8& GetValueRef();
   1.507 +
   1.508 +    /**
   1.509 +    * Get property maximum value of integer property
   1.510 +    * 
   1.511 +    * @since S60 5.0
   1.512 +    * @param  aMaxValue Maximum value to get
   1.513 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.514 +    * a correct type
   1.515 +    */
   1.516 +    IMPORT_C void GetMaxValue( TInt& aMaxValue ) const;
   1.517 +
   1.518 +    /**
   1.519 +    * Get property minimum value of integer property
   1.520 +    * 
   1.521 +    * @since S60 5.0
   1.522 +    * @param  aMinValue Minimum value to get
   1.523 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.524 +    * a correct type
   1.525 +    */
   1.526 +    IMPORT_C void GetMinValue( TInt& aMinValue ) const;
   1.527 +
   1.528 +    /**
   1.529 +    * Set property maximum value of integer property
   1.530 +    * 
   1.531 +    * @since S60 5.0
   1.532 +    * @param  aMaxValue Maximum value to be set
   1.533 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.534 +    * a correct type
   1.535 +    */
   1.536 +    IMPORT_C void SetMaxValue( TInt aMaxValue );
   1.537 +
   1.538 +    /**
   1.539 +    * Set property minimum value of integer property
   1.540 +    * 
   1.541 +    * @since S60 5.0
   1.542 +    * @param  aMinValue Minimum value to be set
   1.543 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.544 +    * a correct type
   1.545 +    */
   1.546 +    IMPORT_C void SetMinValue( TInt aMinValue );
   1.547 +
   1.548 +    /**
   1.549 +    * Get property maximum value of real property
   1.550 +    * 
   1.551 +    * @since S60 5.0
   1.552 +    * @param  aMaxValue Maximum value to get
   1.553 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.554 +    * a correct type
   1.555 +    */
   1.556 +    IMPORT_C void GetMaxValue( TReal& aMaxValue ) const;
   1.557 +
   1.558 +    /**
   1.559 +    * Get property minimum value of real property
   1.560 +    * 
   1.561 +    * @since S60 5.0
   1.562 +    * @param aMinValue Minimum value to get
   1.563 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.564 +    * a correct type
   1.565 +    */
   1.566 +    IMPORT_C void GetMinValue( TReal& aMinValue ) const;
   1.567 +
   1.568 +    /**
   1.569 +    * Set property maximum value of real property
   1.570 +    * 
   1.571 +    * @since S60 5.0
   1.572 +    * @param  aMaxValue Maximum value to be set.
   1.573 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.574 +    * a correct type
   1.575 +    */
   1.576 +    IMPORT_C void SetMaxValue( const TReal& aMaxValue );
   1.577 +
   1.578 +    /**
   1.579 +    * Set property minimum value of real property
   1.580 +    * 
   1.581 +    * @since S60 5.0
   1.582 +    * @param  aMinValue Minimum value to be set.
   1.583 +    * @panic  KSensrvPanicCategory ESensrvPanicInvalidPropertyType Panic if the property object is not
   1.584 +    * a correct type
   1.585 +    */
   1.586 +    IMPORT_C void SetMinValue( const TReal& aMinValue );
   1.587 +
   1.588 +    /**
   1.589 +    * Set security info of the property. This should be set to the Security info for the client process
   1.590 +    * 
   1.591 +    * @since S60 5.0
   1.592 +    * @param aSecurityInfo Security info to be set
   1.593 +    */
   1.594 +    IMPORT_C void SetSecurityInfo( const TSecurityInfo& aSecurityInfo );
   1.595 +
   1.596 +    /**
   1.597 +    * Get security info of the property
   1.598 +    * 
   1.599 +    * @since S60 5.0
   1.600 +    * @return Security info of the property
   1.601 +    */
   1.602 +    IMPORT_C TSecurityInfo GetSecurityInfo() const;
   1.603 +
   1.604 +    /**
   1.605 +    * Set array index of the property.
   1.606 +    * 
   1.607 +    * @since S60 5.0
   1.608 +    * @param aArrayIndex Array index to be set
   1.609 +    * @see TSensrvArrayIndex
   1.610 +    * @see KSensrvPropIdDataRate for an example
   1.611 +    */
   1.612 +    IMPORT_C void SetArrayIndex( const TInt aArrayIndex );
   1.613 +
   1.614 +    /**
   1.615 +    * Get array index of the property
   1.616 +    * 
   1.617 +    * @since S60 5.0
   1.618 +    * @return Array index of the property.
   1.619 +    * @see TSensrvArrayIndex
   1.620 +    * @see KSensrvPropIdDataRate for an example
   1.621 +    */
   1.622 +    IMPORT_C TInt GetArrayIndex() const;
   1.623 +
   1.624 +private:
   1.625 +    // property identifier
   1.626 +    TSensrvPropertyId iPropertyId;
   1.627 +
   1.628 +    // property item index
   1.629 +    TInt iItemIndex;
   1.630 +
   1.631 +    //Array index
   1.632 +    TInt16 iArrayIndex;
   1.633 +
   1.634 +
   1.635 +    // property value
   1.636 +    union
   1.637 +        {
   1.638 +        TInt iIntValue;
   1.639 +        TReal iRealValue;
   1.640 +        };
   1.641 +    TBuf8<KSensrvPropertyTextBufferSize> iBufValue;
   1.642 +
   1.643 +    // read only flag
   1.644 +    TBitFlags32 iFlags;
   1.645 +
   1.646 +    // maximum value
   1.647 +    union
   1.648 +        {
   1.649 +        TInt iIntValueMax;
   1.650 +        TReal iRealValueMax;
   1.651 +        };
   1.652 +
   1.653 +    // minimum value
   1.654 +    union
   1.655 +        {
   1.656 +        TInt iIntValueMin;
   1.657 +        TReal iRealValueMin;
   1.658 +        };
   1.659 +
   1.660 +    // property type
   1.661 +    TSensrvPropertyType iPropertyType;
   1.662 +
   1.663 +    // property security infomation
   1.664 +    TSecurityInfo iSecurityInfo;
   1.665 +
   1.666 +    // not used
   1.667 +    TInt iReserved;
   1.668 +    };
   1.669 +
   1.670 +#endif //SENSRVPROPERTY_H
   1.671 +
   1.672 +// End of File
   1.673 +
   1.674 +