Home Manual Reference Source Repository
public class | source

MoneySpanSet

Represents a unique set of MoneySpan objects.

Constructor Summary

Public Constructor
public

Create an empty MoneySpanSet.

Member Summary

Private Members
private

_allSpans: *[]

private

Method Summary

Public Methods
public

add(moneySpan: MoneySpan)

Add a new span to the set.

public

findByElement(element: type): undefined | MoneySpan

Find a span by the element it renders to.

public

Returns a list of all the spans in the set.

Public Constructors

public constructor() source

Create an empty MoneySpanSet.

Private Members

private _allSpans: *[] source

private _spansByElement: Object<String, MoneySpan> source

Public Methods

public add(moneySpan: MoneySpan) source

Add a new span to the set.

Params:

NameTypeAttributeDescription
moneySpan MoneySpan

Span to add

public findByElement(element: type): undefined | MoneySpan source

Find a span by the element it renders to.

Params:

NameTypeAttributeDescription
element type

The element the span renders to.

Return:

undefined | MoneySpan

public list(): MoneySpan[] source

Returns a list of all the spans in the set.

Return:

MoneySpan[]