CCollection Class Reference

class CCollection : public CBase

Collection of HID report descriptor A CCollection represents an individual collection within a HID report descriptor. Each collection may have a number of associated report fields (CField objects) and a number of child collection objects. The collections within a HID report descriptor form a tree structure, with a CReportRoot collection at the root. The tree is generated by CParser.

generichid.lib
Since
S60 v5.0

Inherits from

Constructor & Destructor Documentation

CCollection()

CCollection()[protected]

~CCollection()

~CCollection()[virtual]

Destructor.

Member Functions Documentation

AddCollectionL()

CCollection *AddCollectionL()

Called when a new collection object has been encountered in the report descriptor. This creates a new CCollection object and adds it to the current list

Since
S60 v5.0

AddFieldL()

CField *AddFieldL()

Called when a new field object has been encountered in the report descriptor. This creates a new field object and adds it the the current list

Since
S60 v5.0

CollectionByIndex(TInt)

IMPORT_C const CCollection *CollectionByIndex(TIntaIndex)const

Returns a pointer to a specific collection from the list of collections

Since
S60 v5.0

Parameters

TInt aIndexThe index of the required collection

CollectionCount()

IMPORT_C TIntCollectionCount()const

Get number of collections

Since
S60 v5.0

ConstructL()

voidConstructL()[protected]

FieldByIndex(TInt)

IMPORT_C const CField *FieldByIndex(TIntaIndex)const

Returns a pointer to the field object at the given index within the field list

Since
S60 v5.0

Parameters

TInt aIndexThe offset within the current field list

FieldCount()

IMPORT_C TIntFieldCount()const

Gets numbers of field stored in collection

Since
S60 v5.0

IsApplication()

IMPORT_C TBoolIsApplication()const

Check if collection type is application

Since
S60 v5.0

IsLogical()

IMPORT_C TBoolIsLogical()const

Check if collection type is logical

Since
S60 v5.0

IsNamedArray()

IMPORT_C TBoolIsNamedArray()const

Check if collection type is name array

Since
S60 v5.0

IsPhysical()

IMPORT_C TBoolIsPhysical()const

Check if collection type is physical

Since
S60 v5.0

IsReport()

IMPORT_C TBoolIsReport()const

Check if collection type is report

Since
S60 v5.0

IsUsageModifier()

IMPORT_C TBoolIsUsageModifier()const

Check if collection type is usage modifier

Since
S60 v5.0

IsUsageSwitch()

IMPORT_C TBoolIsUsageSwitch()const

Check if collection type is usage switch

Since
S60 v5.0

NewL()

CCollection *NewL()[static]

NewLC()

CCollection *NewLC()[static]

SetType(TUint32)

voidSetType(TUint32aType)

Set Collection type

Since
S60 v5.0

Parameters

TUint32 aType

SetUsage(TInt)

voidSetUsage(TIntaUsage)

Set usage

Since
S60 v5.0

Parameters

TInt aUsage

SetUsagePage(TInt)

voidSetUsagePage(TIntaUsagePage)

Set usage page

Since
S60 v5.0

Parameters

TInt aUsagePage

Type()

IMPORT_C TUint32Type()const

Get collection type

Since
S60 v5.0

Usage()

IMPORT_C TIntUsage()const

Get usagepage

Since
S60 v5.0

UsagePage()

IMPORT_C TIntUsagePage()const

Get usagepage

Since
S60 v5.0

Member Enumerations Documentation

Enum TType

An enumerations giving the possible types of collection, as given in "USB Device Class Definition for Human Interface Devices (HID)", Firmware Specification, Version 1.11, USB Implementers' Forum, June 2001.

Note that a TUint32 is used for CCollection::iType, as it is possible to have a vendor defined collection type that isn't included in this list.

Enumerators

EPhysical = 0x00
EApplication = 0x01
ELogical = 0x02
EReport = 0x03
ENamedArray = 0x04
EUsageSwitch = 0x05
EUsageModifier = 0x06

Member Data Documentation

RPointerArray< CCollection > iCollections

RPointerArray< CCollection >iCollections[private]

List of collections for the report descriptor

RPointerArray< CField > iFields

RPointerArray< CField >iFields[private]

List of fields in the current collection

TUint32 iType

TUint32 iType[private]

Collection type

TInt iUsage

TInt iUsage[private]

Usage

TInt iUsagePage

TInt iUsagePage[private]

Usage page