Represents a value of variant or template option that is associated to a specific Orderline.
It allows access to variant/template option types and variant/template_option values associated with the choice.
Returns the key under which the option is stored on the orderline. This typically corresponds to the associated variant or template option type's code.
Returns the value stored on the orderline for this option. This typically corresponds to the associated variant or template option variant's code. In case of text variants/template options, it contains the text provided by the user.
If this option represents a variant, returns the corresponding OptionType object, otherwise returns nil
.
If this option represents a multiple choice variant, returns the corresponding OptionValue object, otherwise returns nil
.
If this option represents a template option, returns the corresponding OptionType object, otherwise returns nil
.
If this option represents a multiple choice template option, returns the corresponding OptionValue object, otherwise returns nil
.
This is equivalent to chosen_option.variant
if option represents a product variant, or chosen_option.template_option
if it represents a template option.
This is equivalent to chosen_option.variant_value
if option represents a product variant, or chosen_option.template_option_value
if it represents a template option.