{!See https://docs.google.com/document/d/1takg_GmIBBKKTj-GHZCwzxohpQz7Bhekivkk72kYMtE/edit for reference implementation of OneTrust, dataLayer and GTM} {!OneTrust Cookies Consent} {!OneTrust Cookies Consent end} {!dataLayer initialization push} {!dataLayer initialization push end} {!Google Tag Manager} {!Google Tag Manager end} Interface IValidatableElement<TValueType> | App UI | 0.6.5
docs.unity3d.com
Search Results for

    Show / Hide Table of Contents

    Interface IValidatableElement<TValueType>

    Interface used on UI elements which handle value validation. Value validation implies the UI element has a value property, hence this interface inherits from UnityEngine.UIElements.INotifyValueChanged<T>.

    Inherited Members
    INotifyValueChanged<TValueType>.SetValueWithoutNotify(TValueType)
    INotifyValueChanged<TValueType>.value
    Namespace: Unity.AppUI.UI
    Assembly: solution.dll
    Syntax
    public interface IValidatableElement<TValueType> : INotifyValueChanged<TValueType>
    Type Parameters
    Name Description
    TValueType

    The type of the value.

    Properties

    Name Description
    invalid

    True if the current value set on the UI element is invalid, False otherwise. The invalid state is handled by the returned result of the validateValue function.

    validateValue

    Set this property to a reference of your custom function which will validate the current value of a UI element. This function will be invoked automatically by the UI element implementation in order to update the invalid state property.

    If the property is `null`, there wont be any validation process so by convention the `value` will be always valid.

    In This Article
    Back to top
    Copyright © 2023 Unity Technologies — Trademarks and terms of use
    • Legal
    • Privacy Policy
    • Cookie Policy
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)