CxId

Description

struct Tinman.Core.Cx.CxId

Represents a Code-X identifier, which must start with a letter or underscore, followed by any number of letters, underscores or digits.

See also

CxName

Public / Constants

Invalid


public static readonly attribute Invalid → (CxId)

The CxId that represents the invalid empty identifier.

Invalid identifier have the string representation ? and are not parseable.

See also

CxId.IsInvalid

Public / Constructors

From​Source


public static method FromSource → (1)

source in : string

[not-null]
The source code.

returns → CxId

The parsed identifier.

Parses the given identifier.

ValidatingException

If the syntax of source in is invalid.

See also

CxCodeUnit

Public / Methods

Append


[Pure]
public method Append → (2)

other in : CxId

The identifier to add.

isGlobal opt : bool = false

Create a global name?

returns → CxName

The resulting name. Will be invalid if this name or the given other in is invalid.

Concatenates this identifier and the given other in one.

To​Name


[Pure]
public method ToName → (1)

isGlobal opt : bool = false

Create a global name?

returns → CxName

The resulting name.

Converts this identifier to a name.

Public / Attributes

Is​Invalid


public attribute IsInvalid → (get)

value : bool

true if this name is equal to Invalid,
false if not.

Returns whether this is the invalid empty identifier.

Name


public attribute Name → (get)

value : string

[not-empty]
The identifier.

Returns the identifier.