[#BloombergLP-bdlar-ChoiceConstRef] = xref:BloombergLP.adoc[BloombergLP]::xref:BloombergLP/bdlar.adoc[bdlar]::ChoiceConstRef :relfileprefix: ../../ :mrdocs: == Synopsis Declared in `<bdlar_choiceref.h>` [source,cpp,subs="verbatim,replacements,macros,-callouts"] ---- class ChoiceConstRef; ---- == Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bdlar/ChoiceConstRef/2constructor-07.adoc[`ChoiceConstRef`] [.small]#[constructor]# | Constructors | xref:BloombergLP/bdlar/ChoiceConstRef/accessSelection.adoc[`accessSelection`] | Invoke the specified `accessor` on the (non‐modifiable) selection, 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& refOrValue, const t_INFO& info); ` Return the value returned from the invocation of `accessor`. The behavior is undefined unless `selectionId() != ‐1`. | xref:BloombergLP/bdlar/ChoiceConstRef/hasSelection-0e.adoc[`hasSelection`] | `hasSelection` overloads | xref:BloombergLP/bdlar/ChoiceConstRef/objectAddress.adoc[`objectAddress`] | Return a pointer to the wrapped array. | xref:BloombergLP/bdlar/ChoiceConstRef/selectionId.adoc[`selectionId`] | Return the id of the current selection if the selection is defined, and ‐1 otherwise. | xref:BloombergLP/bdlar/ChoiceConstRef/vtable.adoc[`vtable`] | Return a pointer to the vtable. | xref:BloombergLP/bdlar/ChoiceConstRef/xsdName.adoc[`xsdName`] | Return the `bdlat_TypeName::xsdName` value for the underlying object. |=== == Non-Member Functions [cols="1,4"] |=== | Name| Description | xref:BloombergLP/bdlar/bdlat_TypeName_xsdName-0e9.adoc[`bdlat_TypeName_xsdName`] | Return the XSD name for the specified `ref` using the specified `format`. | xref:BloombergLP/bdlar/bdlat_choiceAccessSelection-0308.adoc[`bdlat_choiceAccessSelection`] | Invoke the specified `accessor` on the current selection of the specified `ref`. Return the value from the invocation of `accessor`. | xref:BloombergLP/bdlar/bdlat_choiceHasSelection-01.adoc[`bdlat_choiceHasSelection`] | Return `true` if the specified `ref` has the selection identified by the specified `selectionId`, and `false` otherwise. | xref:BloombergLP/bdlar/bdlat_choiceHasSelection-0d.adoc[`bdlat_choiceHasSelection`] | Return `true` if the specified `ref` has the selection identified by the specified `selectionName` of the specified `selectionNameLength`, and `false` otherwise. | xref:BloombergLP/bdlar/bdlat_choiceSelectionId-0eb.adoc[`bdlat_choiceSelectionId`] | Return the id of the current selection if the selection is defined, and ‐1 otherwise. |=== [.small]#Created with https://www.mrdocs.com[MrDocs]#