CxLibrary

Description

sealed class Tinman.Core.Cx.CxLibrary

Derived from

CxNode abstract

A library is a collection of CxCodeUnit objects.

A CxLibrary object is used to group CxCodeUnit objects logically, so that they may resolve their references.

Public / Constructors

Cx​Library


public constructor CxLibrary → (1)

codeUnits opt : IBagConst<CxCodeUnit> = null

The code unit list or null for an empty list. See CodeUnits.

Creates a new instance of CxLibrary.

Public / Methods

Add


public method Add → (1)

codeUnit in : CxCodeUnit

[not-null]
The code unit to add.

returns → bool

true if the code unit has been added,
false if another code unit with the same declaration name already exists.

Adds the given code unit to this library.

Public / Attributes

Code​Units


[Constant]
public attribute CodeUnits → (get)

value : ISortedMapConst<CxName, CxCodeUnit>

[not-null]
The code units, mapped by CxCodeUnit.DeclarationName.

Returns the code units in this library.