#include <lbspositioninfo.h>
Link against: lbs.lib
class HPositionGenericInfo : public TPositionInfo |
Public Member Functions | |
---|---|
IMPORT_C TInt | BufferSize() |
IMPORT_C void | ClearPositionData() |
IMPORT_C void | ClearRequestedFields() |
IMPORT_C TPositionFieldId | FirstRequestedFieldId() |
TInt | GetValue(TPositionFieldId, TType &) |
IMPORT_C TBool | IsFieldAvailable(TPositionFieldId) |
IMPORT_C TInt | IsRequestedField(TPositionFieldId) |
IMPORT_C TInt | MaxFields() |
IMPORT_C HPositionGenericInfo * | New(TInt, TInt) |
IMPORT_C HPositionGenericInfo * | NewL(TInt, TInt) |
IMPORT_C HPositionGenericInfo * | NewLC(TInt, TInt) |
IMPORT_C TPositionFieldId | NextRequestedFieldId(TPositionFieldId) |
IMPORT_C TInt | SetRequestedField(TPositionFieldId) |
IMPORT_C TInt | SetRequestedFields(const TPositionFieldIdList) |
TInt | SetValue(TPositionFieldId, const TType &) |
Class for getting arbitrary positioning related information back from the location server. The client can set upto KPositionMaxRequestedFields as the number of requested fields. The definitions of the fields are given in the enum _TPositionFieldId. The client must know what data type will be returned for each of the fields. The server will make a best attempt to fill in the requested fields.
The client needs to allocate a big enough buffer to store the information it is requesting. In order to be sure of getting back all the information the client must know and allocate memory considering the return value for each requested field.
IMPORT_C TInt | BufferSize | ( | ) | const |
Method returns the size of the buffer set in the constructor
IMPORT_C void | ClearPositionData | ( | ) |
Resets the object to clear all info to that as it was on construction except the requested fields. Use in the server to clear the info before putting together a new location fix and passing it back to the client.
IMPORT_C TPositionFieldId | FirstRequestedFieldId | ( | ) | const |
Looks through the list of requested fields for the lowest valued field Id.
TInt | GetValue | ( | TPositionFieldId | aFieldId, |
TType & | aValue | |||
) | const [inline] |
Used to retrieve position information.
Parameters | |
---|---|
aFieldId | Standard position field identifier. See _TPositionFieldId |
aValue | The parameter aValue can be of the type TInt8, TInt16, TInt32, TInt64, TUint8, TUint16, TUint32, TReal32, TReal64, TTime, TTimeIntervalMicroSeconds, Des8, or Des16. Panics with EPositionGenericInfoMismatchDataType if there is a mismatch in the data type of a field. |
IMPORT_C TBool | IsFieldAvailable | ( | TPositionFieldId | aFieldId | ) | const |
Looks through the available fields and returns whether aFieldId is in the list.
Parameters | |
---|---|
aFieldId | This is the field Id that is searched for. |
IMPORT_C TInt | IsRequestedField | ( | TPositionFieldId | aFieldId | ) | const |
Returns whether a field has been set as requested.
Parameters | |
---|---|
aFieldId | Field Id to search for. |
IMPORT_C TInt | MaxFields | ( | ) | const |
IMPORT_C HPositionGenericInfo * | New | ( | TInt | aBufferSize = KPositionGenericInfoDefaultBufferSize , |
TInt | aMaxFields = KPositionGenericInfoDefaultMaxFields | |||
) | [static] |
Non-leaving constructor that allocs a HPositionGenericInfo on the heap.
Parameters | |
---|---|
aBufferSize | Sets the size of the buffer that the HPositionGenericInfo will have. |
aMaxFields | Sets the maximum number of fields that the HPositionGenericInfo will have. |
IMPORT_C HPositionGenericInfo * | NewL | ( | TInt | aBufferSize = KPositionGenericInfoDefaultBufferSize , |
TInt | aMaxFields = KPositionGenericInfoDefaultMaxFields | |||
) | [static] |
Leaving constructor that allocs a HPositionGenericInfo on the heap.
Parameters | |
---|---|
aBufferSize | Sets the size of the buffer that the HPositionGenericInfo will have. |
aMaxFields | Sets the maximum number of fields that the HPositionGenericInfo will have. |
IMPORT_C HPositionGenericInfo * | NewLC | ( | TInt | aBufferSize = KPositionGenericInfoDefaultBufferSize , |
TInt | aMaxFields = KPositionGenericInfoDefaultMaxFields | |||
) | [static] |
Leaving constructor that allocs a HPositionGenericInfo on the heap and leaves a pointer to the object on the cleanup stack.
Parameters | |
---|---|
aBufferSize | Sets the size of the buffer that the HPositionGenericInfo will have. |
aMaxFields | Sets the maximum number of fields that the HPositionGenericInfo will have. |
IMPORT_C TPositionFieldId | NextRequestedFieldId | ( | TPositionFieldId | aFieldId | ) | const |
Looks for the next field Id in the list greater than aFieldId.
Parameters | |
---|---|
aFieldId | Function will return next field Id in the list greater than this Id. |
IMPORT_C TInt | SetRequestedField | ( | TPositionFieldId | aFieldId | ) |
Method sets a field as requested.
Parameters | |
---|---|
aFieldId | Field Id to be set as requested. |
IMPORT_C TInt | SetRequestedFields | ( | const TPositionFieldIdList | aFieldIdList | ) |
Sets multiple TPositionFieldId objects as requested.
Parameters | |
---|---|
aFieldIdList | List of field Id's to be set as requested. The list is terminated with a EPositionFieldNone entry. |
TInt | SetValue | ( | TPositionFieldId | aFieldId, |
const TType & | aValue | |||
) | [inline] |
Used to store position information.
Parameters | |
---|---|
aFieldId | Standard position field identifier. See _TPositionFieldId |
aValue | The parameter aValue can be of the type TInt8, TInt16, TInt32, TInt64, TUint8, TUint16, TUint32, TReal32, TReal64, TTime, TTimeIntervalMicroSeconds, Des8, or Des16. |