Table of Contents

Class EzrCharacterList

Namespace
EzrSquared.Runtime.Types.Core.Text
Assembly
ezrSquared-lib.dll

The System.Text.StringBuilder type object.

public class EzrCharacterList : EzrObject, IEzrMutableObject, IMutable<IEzrMutableObject>, IEzrString, IEzrIndexedCollection, IEzrEnumerable, IEzrObject
Inheritance
object
EzrCharacterList
Implements
Inherited Members

Constructors

EzrCharacterList(string, Context, Position, Position)

Creates a new EzrCharacterList.

public EzrCharacterList(string value, Context parentContext, Position startPosition, Position endPosition)

Parameters

value string

The base string value.

parentContext Context

The parent context.

startPosition Position

The starting position of the object.

endPosition Position

The ending position of the object.

Fields

Value

The System.Text.StringBuilder value.

public readonly StringBuilder Value

Field Value

StringBuilder

Properties

Count

Gets the number of elements in the collection.

[WrapMember("length", false, false)]
public int Count { get; }

Property Value

int

The number of elements in the collection.

StringValue

Calls System.Text.StringBuilder.ToString() and returns the System.Text.StringBuilder value converted to a string.

public string StringValue { get; }

Property Value

string

Tag

The tag of the type of this object, similar to C# namespace naming conventions.

public override string Tag { get; protected internal set; }

Property Value

string

TypeName

The name of the type of this object, in plain text, all lowercase. Spaces are allowed.

public override string TypeName { get; protected internal set; }

Property Value

string

Methods

Addition(IEzrObject, RuntimeResult)

Appends the string representation of the other object to the current object.

public override void Addition(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

At(int)

Gets the object at the specified index.

public IEzrObject At(int index)

Parameters

index int

The index.

Returns

IEzrObject

The object at the index.

Compare(IEzrIndexedCollection)

Compares the current character list with another collection.

private bool Compare(IEzrIndexedCollection other)

Parameters

other IEzrIndexedCollection

The other collection.

Returns

bool

The result of the comparison.

ComparisonEqual(IEzrObject, RuntimeResult)

Compares the object to another, checks equality.

public override void ComparisonEqual(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

ComparisonGreaterThan(IEzrObject, RuntimeResult)

Compares the object to another, checks if the current object is greater than the other.

public override void ComparisonGreaterThan(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

ComparisonGreaterThanOrEqual(IEzrObject, RuntimeResult)

Compares the object to another, checks if the current object is greater than or equal to the other.

public override void ComparisonGreaterThanOrEqual(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

ComparisonLessThan(IEzrObject, RuntimeResult)

Gets the character(s) at the specified index/indices OR compares the current object to other stringlike objects, checks if this is less than the other.

public override void ComparisonLessThan(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

ComparisonLessThanOrEqual(IEzrObject, RuntimeResult)

Gets the character(s) at the specified index/indices OR compares the current object to other stringlike objects, checks if this is less than or equal to the other.

public override void ComparisonLessThanOrEqual(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

ComparisonNotEqual(IEzrObject, RuntimeResult)

Compares the object to another, checks unequality.

public override void ComparisonNotEqual(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

ComputeHashCode(RuntimeResult)

Evaluates the current object as its hash.

public override int ComputeHashCode(RuntimeResult result)

Parameters

result RuntimeResult

Runtime result for carrying any errors.

Returns

int

The evaluated value.

DeepCopy(RuntimeResult)

Creates a deep copy of the IMutable<T>.

public IMutable<IEzrMutableObject>? DeepCopy(RuntimeResult result)

Parameters

result RuntimeResult

Runtime result for raising errors./

Returns

IMutable<IEzrMutableObject>

The copy, or, null if failed.

Remarks

The deep copy here means that all IMutable<T> properties and fields in the object are also copied.

Division(IEzrObject, RuntimeResult)

Performs the division operation between the current object and another.

public override void Division(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

Remarks

Here, "divide" means "duplicate/decrease the current value X times".

EvaluateBoolean(RuntimeResult)

Evaluates the current object as a boolean value.

public override bool EvaluateBoolean(RuntimeResult result)

Parameters

result RuntimeResult

Runtime result for carrying any errors.

Returns

bool

The evaluated value.

GetEnumerator()

Returns an enumerator that iterates through the collection.

public IEnumerator<IEzrObject> GetEnumerator()

Returns

IEnumerator<IEzrObject>

An enumerator that can be used to iterate through the collection.

GetEnumerator(RuntimeResult)

Similar to System.Collections.Generic.IEnumerable<T>.GetEnumerator().

public IEnumerator<IEzrObject> GetEnumerator(RuntimeResult result)

Parameters

result RuntimeResult

Runtime result for carrying errors.

Returns

IEnumerator<IEzrObject>

The System.Collections.Generic.IEnumerator<T>.

Remarks

Use this when exposing the enumerator to the ezrĀ² runtime. For example, this is used by EzrDictionary to copy read-only keys so that they can't be edited at runtime.

HasValueContained(IEzrObject, RuntimeResult)

Checks if the other object is contained in the current object.

public override void HasValueContained(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

Multiplication(IEzrObject, RuntimeResult)

Performs the multiplication operation between the current object and another.

public override void Multiplication(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

Remarks

Here, "multiply" means "duplicate/decrease the current value X times".

NotHasValueContained(IEzrObject, RuntimeResult)

Checks if the other object is NOT contained in the current object.

public override void NotHasValueContained(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

StrictEquals(IEzrObject, RuntimeResult)

Strictly compares the current object to another, taking into account inheritance.

public override bool StrictEquals(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying any errors.

Returns

bool

Subtraction(IEzrObject, RuntimeResult)

Removes the character(s) at the specified index/indices.

public override void Subtraction(IEzrObject other, RuntimeResult result)

Parameters

other IEzrObject

The other object in the operation.

result RuntimeResult

Runtime result for carrying the result and any errors.

ToPureString(RuntimeResult)

Evaluates the current object as a string value.

public override string ToPureString(RuntimeResult result)

Parameters

result RuntimeResult

Runtime result for carrying any errors.

Returns

string

The evaluated value.

Remarks

This is used to show the 'real' string representation of the object. Like, for example, ToString(RuntimeResult) will
return "example" when called on an EzrString object with value "example", but this function will return example (without quotes).

ToString(RuntimeResult)

Evaluates the current object as a string value.

public override string ToString(RuntimeResult result)

Parameters

result RuntimeResult

Runtime result for carrying any errors.

Returns

string

The evaluated value.