docs.unity3d.com
    Show / Hide Table of Contents

    Class ConfigurationChange

    Defines the changes of a configuration.

    Inheritance
    Object
    ConfigurationChange
    VerifiedConfigurationChange
    Namespace: UnityEngine.Industrial.Configuring.Core
    Syntax
    public class ConfigurationChange

    Constructors

    ConfigurationChange(Configuration, ReadOnlyCollection<Feature>, ReadOnlyCollection<Feature>)

    Creates a new configuration change that is applied to the configuration.

    Declaration
    public ConfigurationChange(Configuration configuration, ReadOnlyCollection<Feature> selectedFeatures, ReadOnlyCollection<Feature> deselectedFeatures)
    Parameters
    Type Name Description
    Configuration configuration

    The configuration.

    ReadOnlyCollection<Feature> selectedFeatures

    The selected features.

    ReadOnlyCollection<Feature> deselectedFeatures

    The deselected features.

    Exceptions
    Type Condition
    ArgumentNullException

    Configuration must not be null

    Properties

    configuration

    Configuration to which this change is tied to. If the configuration is changed, the configuration change becomes stale (isStale).

    Declaration
    public Configuration configuration { get; }
    Property Value
    Type Description
    Configuration

    The configuration.

    deselectedFeatures

    List of features that are deselected (may be

    null
    ).

    Declaration
    public ReadOnlyCollection<Feature> deselectedFeatures { get; }
    Property Value
    Type Description
    ReadOnlyCollection<Feature>

    The deselected features.

    isStale

    If

    true
    , the configuration change cannot be applied anymore as the referenced configuration has changed since the creation of this change.

    Declaration
    public bool isStale { get; }
    Property Value
    Type Description
    Boolean

    true if this instance is stale; otherwise, false.

    selectedFeatures

    List of features that are selected (may be

    null
    ).

    Declaration
    public ReadOnlyCollection<Feature> selectedFeatures { get; }
    Property Value
    Type Description
    ReadOnlyCollection<Feature>

    The selected features.

    Methods

    Apply()

    Applies the change to the configuration.

    Declaration
    public void Apply()
    Remarks

    Throws an InvalidOperationException if the change is stale, i.e., the referenced configuration has been changed. Check isStale to see if it is stale.

    Exceptions
    Type Condition
    InvalidOperationException

    The configuration change is stale and cannot be applied

    Back to top
    Copyright © 2023 Unity Technologies — Terms of use
    • Legal
    • Privacy Policy
    • Cookies
    • Do Not Sell or Share My Personal Information
    • Your Privacy Choices (Cookie Settings)
    "Unity", Unity logos, and other Unity trademarks are trademarks or registered trademarks of Unity Technologies or its affiliates in the U.S. and elsewhere (more info here). Other names or brands are trademarks of their respective owners.
    Generated by DocFX on 18 October 2023