|
| template<class TYPE > |
| int | makeSelection (TYPE *object, int selectionId) |
| |
| template<class TYPE > |
| int | makeSelection (TYPE *object, const char *selectionName, int selectionNameLength) |
| |
| template<class TYPE , class MANIPULATOR > |
| int | manipulateSelection (TYPE *object, MANIPULATOR &manipulator) |
| |
| template<class TYPE , class ACCESSOR > |
| int | accessSelection (const TYPE &object, ACCESSOR &accessor) |
| |
| template<class TYPE > |
| bool | hasSelection (const TYPE &object, const char *selectionName, int selectionNameLength) |
| |
| template<class TYPE > |
| bool | hasSelection (const TYPE &object, int selectionId) |
| |
| template<class TYPE > |
| int | selectionId (const TYPE &object) |
| |
| template<class TYPE > |
| int | bdlat_choiceMakeSelection (TYPE *object, int selectionId) |
| |
| template<class TYPE > |
| int | bdlat_choiceMakeSelection (TYPE *object, const char *selectionName, int selectionNameLength) |
| |
| template<class TYPE , class MANIPULATOR > |
| int | bdlat_choiceManipulateSelection (TYPE *object, MANIPULATOR &manipulator) |
| |
| template<class TYPE , class ACCESSOR > |
| int | bdlat_choiceAccessSelection (const TYPE &object, ACCESSOR &accessor) |
| |
| template<class TYPE > |
| bool | bdlat_choiceHasSelection (const TYPE &object, const char *selectionName, int selectionNameLength) |
| |
| template<class TYPE > |
| bool | bdlat_choiceHasSelection (const TYPE &object, int selectionId) |
| |
| template<class TYPE > |
| int | bdlat_choiceSelectionId (const TYPE &object) |
| |
This namespace provides functions that expose "choice" behavior for "choice" types. See the component-level documentation for more information.
This namespace declaration adds the default implementations of the "choice" customization-point functions to bdlat_ChoiceFunctions. These default implementations assume the type of the acted-upon object is a basic-choice type. For more information about basic-choice types, see bdlat_typetraits .
template<class TYPE , class ACCESSOR >
| int bdlat_ChoiceFunctions::accessSelection |
( |
const TYPE & |
object, |
|
|
ACCESSOR & |
accessor |
|
) |
| |
Invoke the specified accessor on the (non-modifiable) selection of the specified object, supplying accessor with the corresponding selection information structure. The supplied accessor must be a callable type that can be called as if it had the following signature:
template <class t_INFO>
int accessor(const SELECTION_TYPE& selection, const t_INFO& info);
Return the value returned from the invocation of accessor.
- Precondition
- The behavior is undefined unless
k_UNDEFINED_SELECTION_ID != selectionId(object).
template<class TYPE , class MANIPULATOR >
| int bdlat_ChoiceFunctions::manipulateSelection |
( |
TYPE * |
object, |
|
|
MANIPULATOR & |
manipulator |
|
) |
| |
Invoke the specified manipulator on the address of the (modifiable) selection of the specified object, supplying manipulator with the corresponding selection information structure. The supplied manipulator must be a callable type that can be called as if it had the following signature:
template <class t_INFO>
int manipulator(SELECTION_TYPE *selection, const t_INFO& info);
Return the value returned from the invocation of manipulator.
- Precondition
- The behavior is undefined unless
k_UNDEFINED_SELECTION_ID != selectionId(*object).