mrtk_developmentreleases/2.0.0releases/2.1.0releases/2.2.0

    Show / Hide Table of Contents

    Class BaseStateModel

    Base class for defining state model logic to use in conjunction with the State class Allows for retrieving current state mode and comparing states

    Inheritance
    Object
    BaseStateModel
    InteractableStates
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Microsoft.MixedReality.Toolkit.UI
    Assembly: cs.temp.dll.dll
    Syntax
    public abstract class BaseStateModel

    Constructors

    BaseStateModel()

    Declaration
    public BaseStateModel()

    BaseStateModel()

    Declaration
    public BaseStateModel()

    BaseStateModel(State)

    Declaration
    public BaseStateModel(State defaultState)
    Parameters
    Type Name Description
    State defaultState

    BaseStateModel(State)

    Declaration
    public BaseStateModel(State defaultState)
    Parameters
    Type Name Description
    State defaultState

    Fields

    allStates

    Declaration
    protected State[] allStates
    Field Value
    Type Description
    State[]

    allStates

    Declaration
    protected State[] allStates
    Field Value
    Type Description
    State[]

    currentState

    Declaration
    protected State currentState
    Field Value
    Type Description
    State

    currentState

    Declaration
    protected State currentState
    Field Value
    Type Description
    State

    stateList

    Declaration
    protected List<State> stateList
    Field Value
    Type Description
    List<State>

    stateList

    Declaration
    protected List<State> stateList
    Field Value
    Type Description
    List<State>

    Methods

    CompareStates()

    Compare all state values, set appropriate current State and return that current State

    Declaration
    public abstract State CompareStates()
    Returns
    Type Description
    State

    Current State after comparing State values

    CompareStates()

    Compare all state values, set appropriate current State and return that current State

    Declaration
    public abstract State CompareStates()
    Returns
    Type Description
    State

    Current State after comparing State values

    CurrentState()

    Return the current State object

    Declaration
    public virtual State CurrentState()
    Returns
    Type Description
    State

    Return the current State object

    CurrentState()

    Return the current State object

    Declaration
    public virtual State CurrentState()
    Returns
    Type Description
    State

    Return the current State object

    GetBit()

    Declaration
    protected int GetBit()
    Returns
    Type Description
    Int32

    GetBit()

    Declaration
    protected int GetBit()
    Returns
    Type Description
    Int32

    GetState(Int32)

    Get the State object with the given index

    Declaration
    public State GetState(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    Returns
    Type Description
    State

    State Object at given index

    GetState(Int32)

    Get the State object with the given index

    Declaration
    public State GetState(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    Returns
    Type Description
    State

    State Object at given index

    GetStates()

    Get list of available States for this State Model

    Declaration
    public abstract State[] GetStates()
    Returns
    Type Description
    State[]

    Array of available State objects

    GetStates()

    Get list of available States for this State Model

    Declaration
    public abstract State[] GetStates()
    Returns
    Type Description
    State[]

    Array of available State objects

    GetStateValue(Int32)

    Get the value of the state with the given index

    Declaration
    public int GetStateValue(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    Returns
    Type Description
    Int32

    value of the state

    GetStateValue(Int32)

    Get the value of the state with the given index

    Declaration
    public int GetStateValue(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    Returns
    Type Description
    Int32

    value of the state

    ImportStates(List<State>)

    Import the list of states into this state model

    Declaration
    public void ImportStates(List<State> states)
    Parameters
    Type Name Description
    List<State> states

    list of state objects to import

    ImportStates(List<State>)

    Import the list of states into this state model

    Declaration
    public void ImportStates(List<State> states)
    Parameters
    Type Name Description
    List<State> states

    list of state objects to import

    SetCurrentState(State)

    Set the current state to the provided State object

    Declaration
    public virtual void SetCurrentState(State state)
    Parameters
    Type Name Description
    State state

    State object to set

    SetCurrentState(State)

    Set the current state to the provided State object

    Declaration
    public virtual void SetCurrentState(State state)
    Parameters
    Type Name Description
    State state

    State object to set

    SetStateListValue(Int32, Int32)

    Declaration
    protected virtual void SetStateListValue(int index, int value)
    Parameters
    Type Name Description
    Int32 index
    Int32 value

    SetStateListValue(Int32, Int32)

    Declaration
    protected virtual void SetStateListValue(int index, int value)
    Parameters
    Type Name Description
    Int32 index
    Int32 value

    SetStateOff(Int32)

    Set the value of the state with given index to off (0)

    Declaration
    public virtual void SetStateOff(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    SetStateOff(Int32)

    Set the value of the state with given index to off (0)

    Declaration
    public virtual void SetStateOff(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    SetStateOn(Int32)

    Set the value of the state with given index to on (1)

    Declaration
    public virtual void SetStateOn(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    SetStateOn(Int32)

    Set the value of the state with given index to on (1)

    Declaration
    public virtual void SetStateOn(int index)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    SetStateValue(Int32, Int32)

    Set value of state with given index to the provided value

    Declaration
    public virtual void SetStateValue(int index, int value)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    Int32 value

    value to set for state

    SetStateValue(Int32, Int32)

    Set value of state with given index to the provided value

    Declaration
    public virtual void SetStateValue(int index, int value)
    Parameters
    Type Name Description
    Int32 index

    index of state to access

    Int32 value

    value to set for state

    In This Article
    • Constructors
      • BaseStateModel()
      • BaseStateModel()
      • BaseStateModel(State)
      • BaseStateModel(State)
    • Fields
      • allStates
      • allStates
      • currentState
      • currentState
      • stateList
      • stateList
    • Methods
      • CompareStates()
      • CompareStates()
      • CurrentState()
      • CurrentState()
      • GetBit()
      • GetBit()
      • GetState(Int32)
      • GetState(Int32)
      • GetStates()
      • GetStates()
      • GetStateValue(Int32)
      • GetStateValue(Int32)
      • ImportStates(List<State>)
      • ImportStates(List<State>)
      • SetCurrentState(State)
      • SetCurrentState(State)
      • SetStateListValue(Int32, Int32)
      • SetStateListValue(Int32, Int32)
      • SetStateOff(Int32)
      • SetStateOff(Int32)
      • SetStateOn(Int32)
      • SetStateOn(Int32)
      • SetStateValue(Int32, Int32)
      • SetStateValue(Int32, Int32)
    Back to top Generated by DocFX