ImmutableDictionary<T,U>

Overview

Dictionary class that maps a given key to a value. Readonly version.

Location

  • Reference:
    • Elements.dll  .NET, .NET Core 6.0, .NET Standard 2.0
    • elements.jar  Cooper
    • Elements.fx  Island, ToffeeV2
    • libElements.fx  Toffee
  • Namespace: RemObjects.Elements.RTL
  • Platforms: .NET, .NET Core 6.0, .NET Standard 2.0, Cooper, Island, Toffee, ToffeeV2
  • Mapped to:


 

constructor Toffee

 

init($New )

Parameters:

  • :

ContainsKey (not nullable T): Boolean Cooper, Island, Toffee, ToffeeV2

Returns true if this key is contained in the dictionary.

 

method ContainsKey(Key: not nullable T): Boolean

 

Boolean ContainsKey(T! Key)

 

func ContainsKey(_ Key: T) -> Boolean

 

Boolean ContainsKey(T Key)

 

Function ContainsKey(Key As T) As Boolean

Parameters:

  • Key:

ContainsKey (not nullable T): Boolean .NET, .NET Core 6.0, .NET Standard 2.0

 

method ContainsKey(Key: not nullable T): Boolean

 

Boolean ContainsKey(T! Key)

 

func ContainsKey(_ Key: T) -> Boolean

 

Function ContainsKey(Key As T) As Boolean

Parameters:

  • Key:

ContainsValue (not nullable U): Boolean Cooper, Island, Toffee, ToffeeV2

Returns true if this value is contained in the dictionary.

 

method ContainsValue(Value: not nullable U): Boolean

 

Boolean ContainsValue(U! Value)

 

func ContainsValue(_ Value: U) -> Boolean

 

Boolean ContainsValue(U Value)

 

Function ContainsValue(Value As U) As Boolean

Parameters:

  • Value:

ContainsValue (not nullable U): Boolean .NET, .NET Core 6.0, .NET Standard 2.0

 

method ContainsValue(Value: not nullable U): Boolean

 

Boolean ContainsValue(U! Value)

 

func ContainsValue(_ Value: U) -> Boolean

 

Function ContainsValue(Value As U) As Boolean

Parameters:

  • Value:

Count

Returns the nr of items in this dictionary.

 

property Count: Int32 read;

 

Int32 Count { get; }

 

var Count: Int32 { get{} }

 

Integer Count { __get; }

 

ReadOnly Property Count() As Int32

ForEach (Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>) Cooper, Island, Toffee, ToffeeV2

Iterate all items in this list and trigger the callback for it.

 

method ForEach(Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

void ForEach(Action<RemObjects.Elements.RTL.KeyValuePair<T,U>> Action)

 

func ForEach(_ Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

void ForEach(Action<RemObjects.Elements.RTL.KeyValuePair<T,U>> Action)

 

Sub ForEach(Action As Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

Parameters:

  • Action:

ForEach (Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>) .NET, .NET Core 6.0, .NET Standard 2.0

 

method ForEach(Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

void ForEach(Action<RemObjects.Elements.RTL.KeyValuePair<T,U>> Action)

 

func ForEach(_ Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

Sub ForEach(Action As Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

Parameters:

  • Action:

GetSequence Cooper, Island, Toffee, ToffeeV2

Returns an iterator for this dictionary, while iterating changes in the dictionary will cause an exception in the iterator.


GetSequence .NET, .NET Core 6.0, .NET Standard 2.0

 

method GetSequence: IEnumerable<KeyValuePair<T, U>>

 

IEnumerable<KeyValuePair<T, U>> GetSequence()

 

func GetSequence() -> IEnumerable<KeyValuePair<T, U>>

 

Function GetSequence() As IEnumerable<KeyValuePair<T, U>>

Item

Get an item by it's key, or null if it's not present.

 

property Item[Key: not nullable T]: nullable U read;

 

U? Item[T! Key] { get; }

 

subscript Item(_ Key: T) -> U? { get{} }

 

U Item[T Key] { __get; }

 

ReadOnly Property Item(Key As T) As U?

Keys

Returns a keys interator.

 

property Keys: not nullable RemObjects.Elements.RTL.ImmutableList<T> read;

 

ReadOnly Property Keys() As RemObjects.Elements.RTL.ImmutableList<T>

MutableVersion Cooper, Island, Toffee, ToffeeV2

creates a copy and returns this as a mutable version.

 

method MutableVersion: not nullable Dictionary<T, U>

 

Dictionary<T, U>! MutableVersion()

 

func MutableVersion() -> Dictionary<T, U>

 

Dictionary<T, U> MutableVersion()

 

Function MutableVersion() As Dictionary<T, U>

MutableVersion .NET, .NET Core 6.0, .NET Standard 2.0

 

method MutableVersion: not nullable Dictionary<T, U>

 

Dictionary<T, U>! MutableVersion()

 

func MutableVersion() -> Dictionary<T, U>

 

Function MutableVersion() As Dictionary<T, U>

UniqueCopy .NET, .NET Core 6.0, .NET Standard 2.0

 

method UniqueCopy: not nullable ImmutableDictionary<T, U>

 

ImmutableDictionary<T, U>! UniqueCopy()

 

func UniqueCopy() -> ImmutableDictionary<T, U>

 

Function UniqueCopy() As ImmutableDictionary<T, U>

UniqueMutableCopy .NET, .NET Core 6.0, .NET Standard 2.0

 

method UniqueMutableCopy: not nullable Dictionary<T, U>

 

Dictionary<T, U>! UniqueMutableCopy()

 

func UniqueMutableCopy() -> Dictionary<T, U>

 

Function UniqueMutableCopy() As Dictionary<T, U>

Values

Iterator for all values in this dictionary.

 

property Values: not nullable IEnumerable<U> read;

 

IEnumerable<U>! Values { get; }

 

// .NET, .NET Core 6.0, .NET Standard 2.0, Island, ToffeeV2
var Values: IEnumerable<U> { get{} }
// Toffee
var Values: INSFastEnumeration<U> { get{} }

 

Iterable<U> Values { __get; }

 

ReadOnly Property Values() As IEnumerable<U>

 

Count

Returns the nr of items in this dictionary.

 

property Count: Int32 read;

 

Int32 Count { get; }

 

var Count: Int32 { get{} }

 

Integer Count { __get; }

 

ReadOnly Property Count() As Int32

Item

Get an item by it's key, or null if it's not present.

 

property Item[Key: not nullable T]: nullable U read;

 

U? Item[T! Key] { get; }

 

subscript Item(_ Key: T) -> U? { get{} }

 

U Item[T Key] { __get; }

 

ReadOnly Property Item(Key As T) As U?

Keys

Returns a keys interator.

 

property Keys: not nullable RemObjects.Elements.RTL.ImmutableList<T> read;

 

ReadOnly Property Keys() As RemObjects.Elements.RTL.ImmutableList<T>

Values

Iterator for all values in this dictionary.

 

property Values: not nullable IEnumerable<U> read;

 

IEnumerable<U>! Values { get; }

 

// .NET, .NET Core 6.0, .NET Standard 2.0, Island, ToffeeV2
var Values: IEnumerable<U> { get{} }
// Toffee
var Values: INSFastEnumeration<U> { get{} }

 

Iterable<U> Values { __get; }

 

ReadOnly Property Values() As IEnumerable<U>

 

constructor Toffee

 

init($New )

Parameters:

  • :

ContainsKey (not nullable T): Boolean Cooper, Island, Toffee, ToffeeV2

Returns true if this key is contained in the dictionary.

 

method ContainsKey(Key: not nullable T): Boolean

 

Boolean ContainsKey(T! Key)

 

func ContainsKey(_ Key: T) -> Boolean

 

Boolean ContainsKey(T Key)

 

Function ContainsKey(Key As T) As Boolean

Parameters:

  • Key:

ContainsValue (not nullable U): Boolean Cooper, Island, Toffee, ToffeeV2

Returns true if this value is contained in the dictionary.

 

method ContainsValue(Value: not nullable U): Boolean

 

Boolean ContainsValue(U! Value)

 

func ContainsValue(_ Value: U) -> Boolean

 

Boolean ContainsValue(U Value)

 

Function ContainsValue(Value As U) As Boolean

Parameters:

  • Value:

ForEach (Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>) Cooper, Island, Toffee, ToffeeV2

Iterate all items in this list and trigger the callback for it.

 

method ForEach(Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

void ForEach(Action<RemObjects.Elements.RTL.KeyValuePair<T,U>> Action)

 

func ForEach(_ Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

void ForEach(Action<RemObjects.Elements.RTL.KeyValuePair<T,U>> Action)

 

Sub ForEach(Action As Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

Parameters:

  • Action:

GetSequence Cooper, Island, Toffee, ToffeeV2

Returns an iterator for this dictionary, while iterating changes in the dictionary will cause an exception in the iterator.


MutableVersion Cooper, Island, Toffee, ToffeeV2

creates a copy and returns this as a mutable version.

 

method MutableVersion: not nullable Dictionary<T, U>

 

Dictionary<T, U>! MutableVersion()

 

func MutableVersion() -> Dictionary<T, U>

 

Dictionary<T, U> MutableVersion()

 

Function MutableVersion() As Dictionary<T, U>

ContainsKey (not nullable T): Boolean .NET, .NET Core 6.0, .NET Standard 2.0

 

method ContainsKey(Key: not nullable T): Boolean

 

Boolean ContainsKey(T! Key)

 

func ContainsKey(_ Key: T) -> Boolean

 

Function ContainsKey(Key As T) As Boolean

Parameters:

  • Key:

ContainsValue (not nullable U): Boolean .NET, .NET Core 6.0, .NET Standard 2.0

 

method ContainsValue(Value: not nullable U): Boolean

 

Boolean ContainsValue(U! Value)

 

func ContainsValue(_ Value: U) -> Boolean

 

Function ContainsValue(Value As U) As Boolean

Parameters:

  • Value:

ForEach (Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>) .NET, .NET Core 6.0, .NET Standard 2.0

 

method ForEach(Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

void ForEach(Action<RemObjects.Elements.RTL.KeyValuePair<T,U>> Action)

 

func ForEach(_ Action: Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

 

Sub ForEach(Action As Action<RemObjects.Elements.RTL.KeyValuePair<T,U>>)

Parameters:

  • Action:

GetSequence .NET, .NET Core 6.0, .NET Standard 2.0

 

method GetSequence: IEnumerable<KeyValuePair<T, U>>

 

IEnumerable<KeyValuePair<T, U>> GetSequence()

 

func GetSequence() -> IEnumerable<KeyValuePair<T, U>>

 

Function GetSequence() As IEnumerable<KeyValuePair<T, U>>

MutableVersion .NET, .NET Core 6.0, .NET Standard 2.0

 

method MutableVersion: not nullable Dictionary<T, U>

 

Dictionary<T, U>! MutableVersion()

 

func MutableVersion() -> Dictionary<T, U>

 

Function MutableVersion() As Dictionary<T, U>

UniqueCopy .NET, .NET Core 6.0, .NET Standard 2.0

 

method UniqueCopy: not nullable ImmutableDictionary<T, U>

 

ImmutableDictionary<T, U>! UniqueCopy()

 

func UniqueCopy() -> ImmutableDictionary<T, U>

 

Function UniqueCopy() As ImmutableDictionary<T, U>

UniqueMutableCopy .NET, .NET Core 6.0, .NET Standard 2.0

 

method UniqueMutableCopy: not nullable Dictionary<T, U>

 

Dictionary<T, U>! UniqueMutableCopy()

 

func UniqueMutableCopy() -> Dictionary<T, U>

 

Function UniqueMutableCopy() As Dictionary<T, U>