StringOp

Description

abstract class Tinman.Core.Formatting.StringOp

Derived from

IStringOp

Abstract base class for IStringOp implementations.

Public / Constructors

Copy

2 overloads


public static method Copy1 → (1)

in : char

The character to copy.

returns → IStringOp

The IStringOp object.

A string operation that copies the given character.


public static method Copy2 → (1)

range in : RangeI

The character range to copy.

returns → IStringOp

The IStringOp object.

A string operation that copies characters in the given code value range.

Replace


public static method Replace → (3)

what in : string

[not-empty]
The token to replace.

with in : string

[not-null]
The replacement token.

direction opt : int32 = 0

The escape processing direction:
= 0 : both directions
> 0 : what in to with in
< 0 : with in to what in

returns → IStringOp

The IStringOp object.

Returns a IStringOp object that replaces the given token (see what in) with the given replacement (see with in).

Public / Methods

Hex


public static method Hex → (1)

prefix in : string

[not-empty]
The prefix to emit before the 4-digit hexadecimal escape literal.

returns → IStringOp

The IStringOp object.

Returns a IStringOp object that replaces individual characters with hexadecimal escape literal.

A character is escaped if one of the following is true:

Protected / Methods

Do​Reverse


[EmptyBody]
protected virtual method DoReverse → ()

returns → IStringOp

The reverse string operation or null iff IStringOp.IsReversible returns false.

Creates the reverse string operation.

This method is only called if IStringOp.IsReversible returns true.