|
||
_LIT_SECURE_ID (name, value) const SSecureId name={value}
Macro for compile-time definition of a secure ID
|
_LIT_VENDOR_ID (name, value) const SVendorId name={value}
Macro for compile-time definition of a vendor ID
|
_INIT_SECURITY_POLICY_FAIL { \
FOUR_TUINT8( \
(TUint8)TSecurityPolicy::ETypeFail, \
(TUint8)0xff, \
(TUint8)0xff, \
(TUint8)0xff \
), \
(TUint32)0xffffffff \
}
Macro for compile-time initialisation of a security policy object that always fails. That is, checks against this policy will always fail, irrespective of the security attributes of the item being checked.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
_LIT_SECURITY_POLICY_FAIL (n) const TStaticSecurityPolicy n = _INIT_SECURITY_POLICY_FAIL
Macro for compile-time definition of a security policy object that always fails. That is, checks against this policy will always fail, irrespective of the security attributes of the item being checked.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
|
_INIT_SECURITY_POLICY_PASS { \
FOUR_TUINT8( \
(TUint8)TSecurityPolicy::ETypePass, \
(TUint8)0xff, \
(TUint8)0xff, \
(TUint8)0xff \
), \
(TUint32)0xffffffff \
}
Macro for compile-time initialisation of a security policy object that always passes. That is, checks against this policy will always pass, irrespective of the security attributes of the item being checked.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
_LIT_SECURITY_POLICY_PASS (n) const TStaticSecurityPolicy n = _INIT_SECURITY_POLICY_PASS
Macro for compile-time definition of a security policy object that always passes. That is, checks against this policy will always pass, irrespective of the security attributes of the item being checked.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
|
_INIT_SECURITY_POLICY_C7 (c1, c2, c3, c4, c5, c6, c7) { \
FOUR_TUINT8( \
(TUint8)TSecurityPolicy::ETypeC7, \
CAPABILITY_AS_TUINT8(c1), \
CAPABILITY_AS_TUINT8(c2), \
CAPABILITY_AS_TUINT8(c3) \
), \
FOUR_TUINT8( \
CAPABILITY_AS_TUINT8(c4), \
CAPABILITY_AS_TUINT8(c5), \
CAPABILITY_AS_TUINT8(c6), \
CAPABILITY_AS_TUINT8(c7) \
) \
}
Macro for compile-time initialisation of a security policy object The policy will check for seven capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_C7 (n, c1, c2, c3, c4, c5, c6, c7) const TStaticSecurityPolicy n = _INIT_SECURITY_POLICY_C7(c1,c2,c3,c4,c5,c6,c7)
Macro for compile-time definition of a security policy object The policy will check for seven capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_C6 (c1, c2, c3, c4, c5, c6) _INIT_SECURITY_POLICY_C7(c1,c2,c3,c4,c5,c6,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for six capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_C6 (n, c1, c2, c3, c4, c5, c6) _LIT_SECURITY_POLICY_C7(n,c1,c2,c3,c4,c5,c6,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for six capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_C5 (c1, c2, c3, c4, c5) _INIT_SECURITY_POLICY_C7(c1,c2,c3,c4,c5,ECapability_None,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for five capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_C5 (n, c1, c2, c3, c4, c5) _LIT_SECURITY_POLICY_C7(n,c1,c2,c3,c4,c5,ECapability_None,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for five capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_C4 (c1, c2, c3, c4) _INIT_SECURITY_POLICY_C7(c1,c2,c3,c4,ECapability_None,ECapability_None,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for four capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_C4 (n, c1, c2, c3, c4) _LIT_SECURITY_POLICY_C7(n,c1,c2,c3,c4,ECapability_None,ECapability_None,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for four capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_C3 (c1, c2, c3) { \
FOUR_TUINT8( \
(TUint8)TSecurityPolicy::ETypeC3, \
CAPABILITY_AS_TUINT8(c1), \
CAPABILITY_AS_TUINT8(c2), \
CAPABILITY_AS_TUINT8(c3) \
), \
(TUint32)0xffffffff \
}
Macro for compile-time initialisation of a security policy object The policy will check for three capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_C3 (n, c1, c2, c3) const TStaticSecurityPolicy n = _INIT_SECURITY_POLICY_C3(c1,c2,c3)
Macro for compile-time definition of a security policy object The policy will check for three capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_C2 (c1, c2) _INIT_SECURITY_POLICY_C3(c1,c2,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for two capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_C2 (n, c1, c2) _LIT_SECURITY_POLICY_C3(n,c1,c2,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for two capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_C1 (c1) _INIT_SECURITY_POLICY_C3(c1,ECapability_None,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for one capability.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_C1 (n, c1) _LIT_SECURITY_POLICY_C3(n,c1,ECapability_None,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for one capability.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning will be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_S3 (sid, c1, c2, c3) { \
FOUR_TUINT8( \
(TUint8)TSecurityPolicy::ETypeS3, \
CAPABILITY_AS_TUINT8(c1), \
CAPABILITY_AS_TUINT8(c2), \
CAPABILITY_AS_TUINT8(c3) \
), \
(TUint32)(sid) \
}
Macro for compile-time initialisation of a security policy object The policy will check for a secure ID and three capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_S3 (n, sid, c1, c2, c3) const TStaticSecurityPolicy n = _INIT_SECURITY_POLICY_S3(sid,c1,c2,c3)
Macro for compile-time definition of a security policy object The policy will check for a secure ID and three capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_S2 (sid, c1, c2) _INIT_SECURITY_POLICY_S3(sid,c1,c2,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for a secure ID and two capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_S2 (n, sid, c1, c2) _LIT_SECURITY_POLICY_S3(n,sid,c1,c2,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for a secure ID and two capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_S1 (sid, c1) _INIT_SECURITY_POLICY_S3(sid,c1,ECapability_None,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for a secure ID and one capability.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_S1 (n, sid, c1) _LIT_SECURITY_POLICY_S3(n,sid,c1,ECapability_None,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for a secure ID and one capability.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_S0 (sid) _INIT_SECURITY_POLICY_S3(sid,ECapability_None,ECapability_None,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for a secure ID.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
|
_LIT_SECURITY_POLICY_S0 (n, sid) _LIT_SECURITY_POLICY_S3(n,sid,ECapability_None,ECapability_None,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for a secure ID.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
|
_INIT_SECURITY_POLICY_V3 (vid, c1, c2, c3) { \
FOUR_TUINT8( \
(TUint8)TSecurityPolicy::ETypeV3, \
CAPABILITY_AS_TUINT8(c1), \
CAPABILITY_AS_TUINT8(c2), \
CAPABILITY_AS_TUINT8(c3) \
), \
(TUint32)(vid) \
}
Macro for compile-time initialisation of a security policy object The policy will check for a vendor ID and three capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_V3 (n, vid, c1, c2, c3) const TStaticSecurityPolicy n = _INIT_SECURITY_POLICY_V3(vid,c1,c2,c3)
Macro for compile-time definition of a security policy object The policy will check for a vendor ID and three capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_V2 (vid, c1, c2) _INIT_SECURITY_POLICY_V3(vid,c1,c2,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for a vendor ID and two capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_V2 (n, vid, c1, c2) _LIT_SECURITY_POLICY_V3(n,vid,c1,c2,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for a vendor ID and two capabilities.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_V1 (vid, c1) _INIT_SECURITY_POLICY_V3(vid,c1,ECapability_None,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for a vendor ID and one capability.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_LIT_SECURITY_POLICY_V1 (n, vid, c1) _LIT_SECURITY_POLICY_V3(n,vid,c1,ECapability_None,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for a vendor ID and one capability.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
If an invlid capability value is specified then, dependant on the compiler, a compile time error or warning be produced which includes the label "__invalid_capability_value"
|
_INIT_SECURITY_POLICY_V0 (vid) _INIT_SECURITY_POLICY_V3(vid,ECapability_None,ECapability_None,ECapability_None)
Macro for compile-time initialisation of a security policy object The policy will check for a vendor ID.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
|
_LIT_SECURITY_POLICY_V0 (n, vid) _LIT_SECURITY_POLICY_V3(n,vid,ECapability_None,ECapability_None,ECapability_None)
Macro for compile-time definition of a security policy object The policy will check for a vendor ID.
The object declared has an implicit conversion to const TSecurityPolicy
TSecurityPolicy
&. Taking the address of the object will return a const TSecurityPolicy*. Explicit conversion to const TSecurityPolicy
TSecurityPolicy
& may be effected by using the function call operator n().
|
TRAP (_r, _s) { \
TInt& __rref = _r; \
__rref = 0; \
{ TRAP_INSTRUMENTATION_START; } \
try { \
__WIN32SEHTRAP \
TTrapHandler* ____t = User::MarkCleanupStack(); \
_s; \
User::UnMarkCleanupStack(____t); \
{ TRAP_INSTRUMENTATION_NOLEAVE; } \
__WIN32SEHUNTRAP \
} \
catch (XLeaveException& l) \
{ \
__rref = l.GetReason(); \
{ TRAP_INSTRUMENTATION_LEAVE(__rref); } \
} \
catch (...) \
{ \
User::Invariant(); \
} \
__CALL_EMPTY_FUNCTION \
{ TRAP_INSTRUMENTATION_END; } \
}
Executes the set of C++ statements _s under a trap harness.
Use this macro as a C++ statement.
_r must be a TInt which has already been declared; if any of the C++ statements _s leaves, then the leave code is returned in _r, otherwise _r is set to KErrNone.
_s can consist of multiple C++ statements; in theory, _s can consist of any legal C++ code but in practice, such statements consist of simple function calls, e.g. Foo() or an assignment of some value to the result of a function call, e.g. functionValue=GetFoo().
A cleanup stack is constructed for the set of C++ statements _s. If any function in _s leaves, objects pushed to the cleanup stack are cleaned-up. In addition, if any of the C++ statements in _s leaves, then remaining C++ code in _s is not executed and any variables which are assigned within that remaining code are not defined.
|
TRAPD (_r, _s) TInt _r; \
{ \
_r = 0; \
{ TRAP_INSTRUMENTATION_START; } \
try { \
__WIN32SEHTRAP \
TTrapHandler* ____t = User::MarkCleanupStack(); \
_s; \
User::UnMarkCleanupStack(____t); \
{ TRAP_INSTRUMENTATION_NOLEAVE; } \
__WIN32SEHUNTRAP \
} \
catch (XLeaveException& l) \
{ \
_r = l.GetReason(); \
{ TRAP_INSTRUMENTATION_LEAVE(_r); } \
} \
catch (...) \
{ \
User::Invariant(); \
} \
__CALL_EMPTY_FUNCTION \
{ TRAP_INSTRUMENTATION_END; } \
}
Executes the set of C++ statements _s under a trap harness.
Use this macro in the same way as you would TRAP, except that the variable _r is defined as part of the macro (and is therefore valid for the rest of the block in which the macro occurs). Often, this saves a line of code.
|
TRAP_IGNORE (_s) { \
{ TRAP_INSTRUMENTATION_START; } \
try { \
__WIN32SEHTRAP \
TTrapHandler* ____t = User::MarkCleanupStack(); \
_s; \
User::UnMarkCleanupStack(____t); \
{ TRAP_INSTRUMENTATION_NOLEAVE; } \
__WIN32SEHUNTRAP \
} \
catch (XLeaveException& l) \
{ \
l.GetReason(); \
{ TRAP_INSTRUMENTATION_LEAVE(l.Reason()); } \
} \
catch (...) \
{ \
User::Invariant(); \
} \
__CALL_EMPTY_FUNCTION \
{ TRAP_INSTRUMENTATION_END; } \
}
Executes the set of C++ statements _s under a trap harness. Any leave code generated is ignored.
Use this macro as a C++ statement.
This macro is functionally equivalent to:
TInt x;
TRAP(x,_s)
or
TRAPD(x,_s)
where the value in 'x' is not used by any subsequent code.
Use this macro as a C++ statement.
_s can consist of multiple C++ statements; in theory, _s can consist of any legal C++ code but in practice, such statements consist of simple function calls, e.g. Foo() or an assignment of some value to the result of a function call, e.g. functionValue=GetFoo().
A cleanup stack is constructed for the set of C++ statements _s. If any function in _s leaves, objects pushed to the cleanup stack are cleaned-up. In addition, if any of the C++ statements in _s leaves, then remaining C++ code in _s is not executed and any variables which are assigned within that remaining code are not defined.
|
typedef TDesC16 TDesC;
Defines a build-independent non-modifiable descriptor.
A 16-bit build variant is generated for a Unicode, non-kernel mode build.
A build-independent type should always be used unless an explicit 8-bit or 16-bit type is required.
typedef TPtrC16 TPtrC;
Defines a build-independent non-modifiable pointer descriptor.
A 16-bit build variant is generated for a Unicode, non-kernel mode build.
A build-independent type should always be used unless an explicit 8-bit or 16-bit type is required.
typedef TDes16 TDes;
Defines a build-independent modifiable descriptor.
A 16-bit build variant is generated for a Unicode, non-kernel mode build.
A build-independent type should always be used unless an explicit 8-bit or 16-bit type is required.
typedef TPtr16 TPtr;
Defines a build-independent modifiable pointer descriptor.
A 16-bit build variant is generated for a Unicode, non-kernel mode build.
A build-independent type should always be used unless an explicit 8-bit or 16-bit type is required.
typedef HBufC16 HBufC;
Defines a build-independent heap descriptor.
A 16-bit build variant is generated for a Unicode, non-kernel mode build.
A build-independent type should always be used unless an explicit 8-bit or 16-bit type is required.
typedef TDes16Overflow TDesOverflow;
Defines a build-independent descriptor overflow handler.
A 16-bit build variant is generated for a Unicode, non-kernel mode build.
A build-independent type should always be used unless an explicit 8-bit or 16-bit type is required.
typedef RBuf16 RBuf;
Defines a build-independent resizable buffer descriptor.
A 16-bit build variant is generated for a Unicode, non-kernel mode build.
A build-independent type should always be used unless an explicit 8-bit or 16-bit type is required.
typedef TRefByValue<const TDesC> __TRefDesC;
Value reference used in operator TLitC::__TRefDesC().
TRefByValue
TRefByValue
A templated class which encapsulates a reference to an object within a wrapper.typedef TBuf<KMaxName> TName;
Defines a modifiable buffer descriptor that can contain the name of a reference counting object.
typedef TBuf<KMaxFullName> TFullName;
Defines a modifiable buffer descriptor that can contain the full name of a reference counting object.
typedef TBuf<KMaxExitCategoryName> TExitCategoryName;
Defines a modifiable buffer descriptor to contain the category name identifying the cause of thread or process termination. The buffer takes a maximum length of KMaxExitCategoryName.
RThread::ExitCategory()const
Gets the name of the category associated with the end of the thread.RThread::ExitCategory()const
Gets the name of the category associated with the end of the thread.typedef TBuf<KMaxFileName> TFileName;
A buffer that can contain the name of a file. The name can have a maximum length of KMaxFileName (currently 256 but check the definition of KMaxFileName).
typedef TBuf<KMaxPath> TPath;
A buffer that can contain the name of a path. The name can have a maximum length of KMaxPath (currently 256 but check the definition of KMaxPath).
typedef TBuf<KMaxVersionName> TVersionName;
Version name type.
This is a buffer descriptor with a maximum length of KMaxVersionName. ATVersion
TVersion
object returns the formatted character representation of its version information in a descriptor of this type.
typedef TBuf<KMaxUidName> TUidName;
Defines a modifiable buffer descriptor for the text form of the UID. The descriptor has a maximum length of KMaxUidName and
is used to contain the standard text format returned by the function TUid::Name()const
.
TUid::Name()const
Generates and returns the standard text form of the UID.typedef TBuf8<KMaxMediaPassword> TMediaPassword;
Defines an 8-bit modifiable buffer descriptor to contain passwords when dealing with password security support in a file server session.
The descriptor takes a maximum length of KMaxMediaPassword.
typedef TPckgBuf<TSecurityPolicy> TSecurityPolicyBuf;
Provides a TPkcgBuf wrapper for a descriptorised TSecurityPolicy
TSecurityPolicy
. This a suitable container for passing a security policy across IPC.
typedef TProcessMemoryInfo TModuleMemoryInfo;
Defines a more useful synonym for TProcessMemoryInfo
TProcessMemoryInfo
.
typedef TBool(* TGeneralIdentityRelation)(const TAny*, const TAny*);
Defines a function type used by a TIdentityRelation
TIdentityRelation
object.
A function of this type implements an algorithm for determining whether two objects match.
TIdentityRelation
TIdentityRelation
A templated class which packages a function that determines whether two objects ...typedef TInt(* TGeneralLinearOrder)(const TAny*, const TAny*);
Defines a function type used by a TLinearOrder
TLinearOrder
object
A function of this type implements an algorithm that determines the order of two objects.
TLinearOrder
TLinearOrder
A templated class which packages a function that determines the order of two obj...IMPORT_C TInt memcompare(const TUint8 *aLeft, TInt aLeftLen, const TUint8 *aRight, TInt aRightLen);
A Nanokernel utility function that compares two memory buffers for equality.
The two buffers are considered equal only if:
1. the buffers have the same length
and
2. the binary content of both buffers is the same.
|
|
|
IMPORT_C TAny* wordmove(TAny *aTrg, const TAny *aSrc, unsigned int aLength);
A Nanokernel utility function that moves (copies) bytes in memory.
The function assumes that the addresses are aligned on word boundaries, and that the length value is a multiple of 4.
|
|
|
IMPORT_C TAny* memclr(TAny *aTrg, unsigned int aLength);
A Nanokernel utility function that sets the specified number of bytes to binary zero.
|
|
IMPORT_C TAny* memset(TAny *aTrg, TInt aValue, unsigned int aLength);
A Nanokernel utility function that sets all of the specified number of bytes to the specified fill value.
|
|
IMPORT_C TAny* memcpy(TAny *aTrg, const TAny *aSrc, unsigned int aLength);
A Nanokernel utility function that copies bytes in memory.
|
|
IMPORT_C TAny* memmove(TAny *aTrg, const TAny *aSrc, unsigned int aLength);
A Nanokernel utility function that moves (copies) bytes in memory.
|
|
inline TInt Lim(TInt aVal, TUint aLimit);
Tests whether the specified value is less than or equal to the specified upper limit.
|
|
inline TInt LimX(TInt aVal, TUint aLimit);
Tests whether the specified value is strictly less than the specified upper limit.
|
|
inline T Min(T aLeft, T aRight);
Returns the smaller of two values.
|
|
inline T Min(T aLeft, TUint aRight);
Returns the smaller of two objects, where the right hand object is a treated as a TInt for the purpose of comparison.
|
|
inline T Max(T aLeft, T aRight);
Returns the larger of two values.
|
|
inline T Max(T aLeft, TUint aRight);
Returns the larger of two objects, where the right hand object is a treated as a TInt for the purpose of comparison.
|
|
inline T Abs(T aVal);
Returns an absolute value.
|
|
inline TBool Rng(T aMin, T aVal, T aMax);
Determines whether a specified value lies within a defined range of values.
|
|
inline T* PtrAdd(T *aPtr, S aVal);
Adds a value to a pointer.
|
|
inline T* PtrSub(T *aPtr, S aVal);
Subtracts a value from a pointer.
|
|
inline T Align2(T aValue);
Aligns the specified value onto a 2-byte boundary.
|
|
inline T Align4(T aValue);
Aligns the specified value onto a 4-byte boundary.
|
|
const TLitC< sizeof(L"")/2 KNullDesC)={sizeof(L"" )/2-1,L"" };
Defines an empty or null literal descriptor.
This is the build independent form. An 8 bit build variant is generated for a non-Unicode build; a 16 bit build variant is generated for a Unicode build.
const TLitC8< sizeof("") KNullDesC8)={sizeof( "" )-1, "" };
Defines an empty or null literal descriptor for use with 8-bit descriptors.
const TLitC16< sizeof(L"")/2 KNullDesC16)={sizeof(L"" )/2-1,L"" };
Defines an empty or null literal descriptor for use with 16-bit descriptors