logo SERENITY
Game Systems Foundation
Search Results for

    Show / Hide Table of Contents

    Class UnityUiSliderComponentFactory

    Factory for creating Unity UI slider components with automatic configuration for numeric value ranges.
    Handles instantiation, initialization, and setup of slider controls including value bounds, step configuration, and display text updates.
    Provides specialized handling for both integer and float value types with appropriate precision settings.

    Inheritance
    object
    UnityUiSliderComponentFactory
    Implements
    IUiComponentFactory
    Inherited Members
    object.ToString()
    object.Equals(object)
    object.Equals(object, object)
    object.ReferenceEquals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    Namespace: Serenity.Ui.Infrastructure.Components.Factories
    Assembly: Serenity.UnityUi.Infrastructure.dll
    Syntax
    public class UnityUiSliderComponentFactory : IUiComponentFactory

    Constructors

    UnityUiSliderComponentFactory(UnityViewElementFactory)

    Initializes the slider component factory with Unity view element factory dependency.
    Sets up the factory with the required view element creation capabilities for slider component instantiation.

    Declaration
    public UnityUiSliderComponentFactory(UnityViewElementFactory unityViewElementFactory)
    Parameters
    Type Name Description
    UnityViewElementFactory unityViewElementFactory

    Factory for creating Unity view elements

    Methods

    CreateUiComponent<Element, Parameters, Actions>(Parameters, Actions, IFoundationViewElement, ILogService)

    Creates and configures a Unity UI slider component from template with full initialization.
    Instantiates the slider component GameObject, applies parameters and actions, and performs specialized slider setup.
    Configures value ranges, step increments, and display text based on the component's value type requirements.

    Declaration
    public Element CreateUiComponent<Element, Parameters, Actions>(Parameters parameters, Actions actions, IFoundationViewElement template, ILogService logService) where Element : IFoundationViewElement where Parameters : IUiComponentParameters where Actions : IUiComponentActions
    Parameters
    Type Name Description
    Parameters parameters

    Configuration parameters for the slider component

    Actions actions

    Action handlers for slider component interactions

    IFoundationViewElement template

    Template foundation view element for component instantiation

    ILogService logService

    Logging service for error reporting and debugging

    Returns
    Type Description
    Element

    Fully configured Unity UI slider component ready for use

    Type Parameters
    Name Description
    Element

    The target UI component element type

    Parameters

    The component parameters type

    Actions

    The component actions type

    Exceptions
    Type Condition
    Exception

    Thrown when component type is unsupported, template is null, or GameObject creation fails

    Implements

    IUiComponentFactory
    In this article
    © 2026 Serenity. All Rights Reserved