Table of Contents

Class TypeKeyedMap<TValue>

Namespace
RisingV.Shared.Collections
Assembly
RisingV.Shared.dll

Represents a map (dictionary) that uses types as keys.

public class TypeKeyedMap<TValue>

Type Parameters

TValue
Inheritance
TypeKeyedMap<TValue>
Inherited Members
Extension Methods

Constructors

TypeKeyedMap(IMap<Type, TValue>?)

Represents a map (dictionary) that uses types as keys.

public TypeKeyedMap(IMap<Type, TValue>? map = null)

Parameters

map IMap<Type, TValue>

Properties

Count

public int Count { get; }

Property Value

int

this[Type]

public TValue this[Type type] { get; set; }

Parameters

type Type

Property Value

TValue

Keys

public IEnumerable<Type> Keys { get; }

Property Value

IEnumerable<Type>

Values

public IEnumerable<TValue> Values { get; }

Property Value

IEnumerable<TValue>

Methods

Add<TX>()

public TX Add<TX>() where TX : TValue

Returns

TX

Type Parameters

TX

Add<TX>(TX)

public void Add<TX>(TX value) where TX : TValue

Parameters

value TX

Type Parameters

TX

Clear()

public void Clear()

Contains<TX>()

public bool Contains<TX>() where TX : TValue

Returns

bool

Type Parameters

TX

GetOrCreate<TX>()

public TX GetOrCreate<TX>() where TX : TValue

Returns

TX

Type Parameters

TX

Remove<TX>()

public TX Remove<TX>() where TX : TValue

Returns

TX

Type Parameters

TX

TryGet<TX>(out TX?)

public bool TryGet<TX>(out TX? value) where TX : TValue

Parameters

value TX

Returns

bool

Type Parameters

TX

TryRemove<TX>()

public TX? TryRemove<TX>() where TX : TValue

Returns

TX

Type Parameters

TX