TUidType Class Reference

#include <e32cmn.h>

class TUidType
Public Member Functions
TUidType()
TUidType(TUid)
TUidType(TUid, TUid)
TUidType(TUid, TUid, TUid)
IMPORT_C TBoolIsPresent(TUid)
IMPORT_C TBoolIsValid()
IMPORT_C TUidMostDerived()
IMPORT_C TBooloperator!=(const TUidType &)
IMPORT_C TBooloperator==(const TUidType &)
IMPORT_C const TUid &operator[](TInt)

Detailed Description

Encapsulates a set of three unique identifiers (UIDs) which, in combination, identify a system object such as a GUI application or a DLL. The three component UIDs are referred to as UID1, UID2 and UID3.

An object of this type is referred to as a compound identifier or a UID type.

Constructor & Destructor Documentation

TUidType ( )

IMPORT_CTUidType()

Default constructor.

Creates a UID type, and sets all three component UIDs to KNullUid.

TUidType ( TUid )

IMPORT_CTUidType(TUidaUid1)

Constructor that creates a UID type and sets the UID1 component to the specified value.

The UID2 and UID3 components are set to KNullUid.

ParameterDescription
aUid1Value for UID1.

TUidType ( TUid, TUid )

IMPORT_CTUidType(TUidaUid1,
TUidaUid2
)

Constructor that creates a UID type and sets the UID1 and UID2 components to the specified values.

The UID3 component is set to KNullUid.

ParameterDescription
aUid1Value for UID1.
aUid2Value for UID2.

TUidType ( TUid, TUid, TUid )

IMPORT_CTUidType(TUidaUid1,
TUidaUid2,
TUidaUid3
)

Constructor that creates a UID type and sets all three UID components to the specified values.

ParameterDescription
aUid1Value for UID1.
aUid2Value for UID2.
aUid3Value for UID3.

Member Function Documentation

IsPresent ( TUid )

IMPORT_C TBoolIsPresent(TUidaUid)const

Tests if any of the component UIDs are equal to the specified UID.

ParameterDescription
aUidThe UID to be tested.

Returns: True, if any one of the component UIDs are the same as the specified UID; false, if none of the component UIDs are the same.

IsValid ( )

IMPORT_C TBoolIsValid()const

Tests the object for a valid (non-KNullUid) UID type.

See also: KNullUid

Returns: True, if at least one of the component UIDs is not KNullUid; false, if all component UIDs are KNullUid.

MostDerived ( )

IMPORT_C TUidMostDerived()const

Gets the most derived UID.

Taking the three UID components as a hierarchy with UID1 being the most general, UID2 being more specific than UID1 and UID3 being more specific than UID2, then the function returns:

UID3, if UID3 is not KNullUid.

UID2, if UID2 is not KNullUid.

UID1, otherwise

See also: KNullUid

Returns: The most derived UID.

operator!= ( const TUidType & )

IMPORT_C TBooloperator!=(const TUidType &aUidType)const

Compares this UID type for inequality with the specified UID type.

ParameterDescription
aUidTypeThe UID type to be compared.

Returns: True, if any component UID is not equal to the corresponding component UID in the specified UID type; false otherwise.

operator== ( const TUidType & )

IMPORT_C TBooloperator==(const TUidType &aUidType)const

Compares this UID type for equality with the specified UID type.

ParameterDescription
aUidTypeThe UID type to be compared.

Returns: True, if each component UID is equal to the corresponding component UID in the specified UID type; false, otherwise.

operator[] ( TInt )

IMPORT_C const TUid &operator[](TIntanIndex)const

Gets the UID component as identified by the specified index.

panic
USER 37 if aIndex is not in the range 0 to 2, inclusive.
ParameterDescription
anIndexIndex value indicating which UID component to return. 0 specifies UID1, 1 specifies UID2, 2 specifies UID3.

Returns: A reference to the required UID component.