docs.unity3d.com
    Show / Hide Table of Contents

    Interface ICreateFromDataPair

    Interface for a relation that can be created from 2 pieces of data and added to a set with 2 children

    Namespace: Unity.MARS.Authoring
    Syntax
    [MovedFrom("Unity.MARS")]
    public interface ICreateFromDataPair

    Methods

    ConformToData(TraitDataSnapshot, TraitDataSnapshot)

    Modifies the properties so that the data is acceptable for this relation

    Declaration
    void ConformToData(TraitDataSnapshot child1Data, TraitDataSnapshot child2Data)
    Parameters
    Type Name Description
    TraitDataSnapshot child1Data

    The data for child 1 that should pass this relation after this method is called

    TraitDataSnapshot child2Data

    The data for child 2 that should pass this relation after this method is called

    FormatDataString(TraitDataSnapshot, TraitDataSnapshot)

    Formats data into a string that is human-readable and appropriate for the relation

    Declaration
    string FormatDataString(TraitDataSnapshot child1Data, TraitDataSnapshot child2Data)
    Parameters
    Type Name Description
    TraitDataSnapshot child1Data

    The data for child 1

    TraitDataSnapshot child2Data

    The data for child 2

    Returns
    Type Description
    String

    The formatted string

    OptimizeForData(TraitDataSnapshot, TraitDataSnapshot)

    Modifies the properties so that the data is the optimal data for this relation

    Declaration
    void OptimizeForData(TraitDataSnapshot child1Data, TraitDataSnapshot child2Data)
    Parameters
    Type Name Description
    TraitDataSnapshot child1Data

    The data that should be optimal for child 1 after this method is called

    TraitDataSnapshot child2Data

    The data that should be optimal for child 2 after this method is called

    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