CodeFactory for Windows CodeFactory for Windows
CodeFactory for Windows CodeFactory for Windows
CodeFactory

Search Results for

    Class ModelStore<T>

    Stores code factory models so they can be extracted when needed.

    Inheritance
    object
    ModelStore<T>
    Inherited Members
    object.Equals(object)
    object.Equals(object, object)
    object.GetHashCode()
    object.GetType()
    object.MemberwiseClone()
    object.ReferenceEquals(object, object)
    object.ToString()
    Namespace: CodeFactory
    Assembly: CodeFactory.dll
    Syntax
    public class ModelStore<T> where T : class
    Type Parameters
    Name Description
    T

    The type of model that is being stored.

    Constructors

    ModelStore()

    Initialization of the model store

    Declaration
    public ModelStore()

    Methods

    AddModel(string, T)

    Adds a model to the model store.

    Declaration
    public void AddModel(string index, T model)
    Parameters
    Type Name Description
    string index

    The unique index for the model.

    T model

    The model to be added to the store. The model cannot be null otherwise it will not be added.

    GetModel(string)

    Gets a target model from the store.

    Declaration
    public T GetModel(string index)
    Parameters
    Type Name Description
    string index

    Index number of the model to load.

    Returns
    Type Description
    T

    The stored model or null if the model could not be returned.

    Remarks

    Thread safe operation.

    © CodeFactory, LLC. All rights reserved.