logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class UiOption

    Represents a UI option with various properties and behaviors.

    Inheritance
    object
    UiOption
    Implements
    IFoundationSettings
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.Ui.Domain.Entities
    Assembly: Serenity.Ui.Domain.dll
    Syntax
    public class UiOption : IFoundationSettings

    Constructors

    UiOption()

    Initializes a new instance of the UiOption class with default values.

    Declaration
    public UiOption()

    UiOption(string, string, string, UiComponentValueType, UiComponentInteractionType, UiOptionValue, UiOptionValue, bool, bool, EventDispatcherSignal)

    Initializes a new instance of the UiOption class with the specified parameters.

    Declaration
    public UiOption(string id, string viewId, string label, UiComponentValueType valueType, UiComponentInteractionType interactionType, UiOptionValue value, UiOptionValue defaultValue, bool isTranslatingLabel, bool isTranslatingValue, EventDispatcherSignal onSubmitSignal)
    Parameters
    Type Name Description
    string id

    The unique identifier of the option.

    string viewId

    The view identifier of the option.

    string label

    The display label of the option.

    UiComponentValueType valueType

    The value type of the option.

    UiComponentInteractionType interactionType

    The interaction type of the option.

    UiOptionValue value

    The current value of the option.

    UiOptionValue defaultValue

    The default value of the option.

    bool isTranslatingLabel

    Whether the label is being translated.

    bool isTranslatingValue

    Whether the value is being translated.

    EventDispatcherSignal onSubmitSignal

    The signal to be dispatched when the option is submitted.

    Fields

    DefaultValue

    Declaration
    public UiOptionValue DefaultValue
    Field Value
    Type Description
    UiOptionValue

    The default value of the option.

    Guid

    Declaration
    public string Guid
    Field Value
    Type Description
    string

    The globally unique identifier of the option.

    Id

    Declaration
    public string Id
    Field Value
    Type Description
    string

    The unique identifier of the option.

    InteractionType

    Declaration
    public UiComponentInteractionType InteractionType
    Field Value
    Type Description
    UiComponentInteractionType

    The interaction type of the option.

    IsTranslatingLabel

    Declaration
    public bool IsTranslatingLabel
    Field Value
    Type Description
    bool

    Whether the label is being translated.

    IsTranslatingValue

    Declaration
    public bool IsTranslatingValue
    Field Value
    Type Description
    bool

    Whether the value is being translated.

    Label

    Declaration
    public string Label
    Field Value
    Type Description
    string

    The display label of the option.

    OnSubmitSignal

    Declaration
    public EventDispatcherSignal OnSubmitSignal
    Field Value
    Type Description
    EventDispatcherSignal

    The signal to be dispatched when the option is submitted.

    Value

    Declaration
    public UiOptionValue Value
    Field Value
    Type Description
    UiOptionValue

    The current value of the option.

    ValueType

    Declaration
    public UiComponentValueType ValueType
    Field Value
    Type Description
    UiComponentValueType

    The value type of the option.

    ViewId

    Declaration
    public string ViewId
    Field Value
    Type Description
    string

    The view identifier of the option.

    Methods

    GetValue()

    Gets the current value of the option.

    Declaration
    public UiOptionValue GetValue()
    Returns
    Type Description
    UiOptionValue

    The current value of the option.

    ToString()

    Gets string representation of the UiOption.

    Declaration
    public override string ToString()
    Returns
    Type Description
    string

    A string representation of the UiOption.

    Overrides
    object.ToString()

    Implements

    IFoundationSettings
    In this article
    © 2026 Serenity. All Rights Reserved