HAL Class Reference

class HAL : public HALData

A set of static functions to get and set hardware attributes.

HALData

Inherits from

Nested Classes and Structures

Member Functions Documentation

Get(TAttribute, TInt &)

IMPORT_C TInt Get ( TAttribute aAttribute,
TInt & aValue
) [static]

Gets the value of the specified HAL attribute.

HALData::TAttribute HALData::TAttributeProperty

Parameters

TAttribute aAttribute The HAL attribute.
TInt & aValue On successful return, contains the attribute value. Some attributes may accept aValue as an input as well, to select one of several alternate values. See the documentation for the individual HAL attributes for details of this.

Get(TInt, TAttribute, TInt &)

IMPORT_C TInt Get ( TInt aDeviceNumber,
TAttribute aAttribute,
TInt & aValue
) [static]

Gets the value of the specified HAL attribute.

HALData::TAttribute HALData::TAttributeProperty

Parameters

TInt aDeviceNumber The device number. (eg: screen number)
TAttribute aAttribute The HAL attribute.
TInt & aValue On successful return, contains the attribute value. Some attributes may accept aValue as an input as well, to select one of several alternate values. See the documentation for the individual HAL attributes for details of this.

GetAll(TInt &, SEntry *&)

IMPORT_C TInt GetAll ( TInt & aNumEntries,
SEntry *& aData
) [static]

Gets all HAL attributes, and their properties.

For attributes that are not meaningful on this device (ie. those which have not been defined in the config.hcf file), the attribute value and its associated property value are set to zero in the returned array.

Attributes for which multiple values can be retrieved ie. EDisplayIsPalettized, EDisplayBitsPerPixel, EDisplayOffsetToFirstPixel, EDisplayOffsetBetweenLines, and EDisplayPaletteEntry will also be zero in the returned array.

Attributes that allocate resources and open handles are also not returned by this API. Their value and property values will be set to zero in the returned array. Use HAL::Get() for these attributes.

Parameters

TInt & aNumEntries On successful return, contains the total number of HAL attributes. If the function returns KErrNoMemory, this value is set to zero.
SEntry *& aData On successful return, contains a pointer to an array of SEntry objects, each of which contains an attribute value and its property value. Note that the property value is defined by the HAL::TEntry synonym. If the function returns KErrNoMemory, this pointer is set to NULL.

Set(TAttribute, TInt)

IMPORT_C TInt Set ( TAttribute aAttribute,
TInt aValue
) [static]

Sets the specified HAL attribute.

HALData::TAttribute HALData::TAttributeProperty
capability
WriteDeviceData or other capability specified for individual attributes in TAttribute

Parameters

TAttribute aAttribute The HAL attribute.
TInt aValue The attribute value.

Set(TInt, TAttribute, TInt)

IMPORT_C TInt Set ( TInt aDeviceNumber,
TAttribute aAttribute,
TInt aValue
) [static]

Sets the specified HAL attribute.

HALData::TAttribute HALData::TAttributeProperty
capability
WriteDeviceData or other capability specified for individual attributes in TAttribute

Parameters

TInt aDeviceNumber The device number. (eg: screen number)
TAttribute aAttribute The HAL attribute.
TInt aValue The attribute value.

Member Enumerations Documentation

Enum TEntryProperty

Synonyms for the attribute properties HALData::TAttributeProperty , and used in SEntry .

Enumerators

EEntryValid = 0x1

When set, means that an attribute is meaningful on this device.

EEntryDynamic = 0x2

When set, means that an attribute is modifiable.