[IoId("00000000-383b-45f5-af4a-69f0c397db09")] public sealed class NTuple : IStorable, IEquatable<NTuple>, IComparable<NTuple>
A combination of one or more named values.

Constructors

NTuple

#
public NTuple(
reader
)

NTuple

#
public NTuple(
params (string name, IPear pear)[]
elements
)

Properties

Count

#
Gets the number of elements.
public int Count { get; }

Elements

#
Enumerate over all elements.
public IEnumerable<(string name, IPear pear)> Elements { get; }

Empty

#
public static NTuple Empty { get; }

Methods

CompareTo

#
public int CompareTo(
other
)

Equals

#
public bool Equals(
other
)

Equals

#
public override bool Equals(
obj
)
Object.Equals

Get<T>

#
Get the value if defined.
public bool Get<T>(
name,
Name of value to retrieve.
comparison,
Comparison to use.
out T
value
Value if defined.
)
True if value was defined.

GetHashCode

#
public override int GetHashCode()

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
pear
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

Grow

#
Add a value to this tuple.
public NTuple Grow(
name,
Name of value to add.
value
Value to add.
)
Tuple with added value.

IndexOf

#
Find the index of the element with the given name.
public int IndexOf(
name,
comparison = StringComparison.Ordinal
)

IsValidName

#
Validate the name for a tuple element. Names may not contain wildcard characters.
public static bool IsValidName(
proposedName,
out string
validName,
out string[]
reasons
)

Name

#
Gets the name of the element at the given index.
public string Name(
index
)

Pare

#
Remove the elements from this tuple with the given name.
public NTuple Pare(
name,
comparison
)

PareWildcard

#
Remove all elements from this tuple which match the given name pattern.
public NTuple PareWildcard(
name
)

Pear

#
Gets the name of the element at the given index.
public IPear Pear(
index
)

Store

#
public void Store(
writer
)
Store

ToString

#
public override string ToString()
Object.ToString

TryGet<T>

#
Try and retrieve the value if defined.
public bool TryGet<T>(
name,
Name of value to retrieve.
comparison,
Comparison to use.
ref T
value
Value if defined.
)
True if value was defined.

Operators