Table of Contents

Class PolymorphicItemTemplate

Namespace
RandomizerCore.LogicItems.Templates
Assembly
RandomizerCore.dll

A reflection-based item template.

public class PolymorphicItemTemplate : ILogicItemTemplate
Inheritance
PolymorphicItemTemplate
Implements
Inherited Members

Properties

Constructor

The constructor to use to instantiate the item. Can be omitted if ItemType is set, in which case the template will look for a constructor which takes a single string parameter.

public ConstructorInfo Constructor { get; set; }

Property Value

ConstructorInfo

ItemType

The type of item to instantiate.

public Type ItemType { get; set; }

Property Value

Type

Name

The "Name" entry in Properties.

public string Name { get; }

Property Value

string

Properties

A case-insenstive collection of properties for the item.

public Dictionary<string, object> Properties { get; }

Property Value

Dictionary<string, object>

Methods

Create(LogicManager)

public LogicItem Create(LogicManager lm)

Parameters

lm LogicManager

Returns

LogicItem

SetProperty(string, object)

public void SetProperty(string key, object value)

Parameters

key string
value object