@drewsonne/maya-dates / Exports / Cycle
↳ Cycle
↳↳ HaabMonth
↳↳ TzolkinDay
• Protected
new Cycle(value
, lookup
, generator
)
Name | Type |
---|---|
value |
string | number | Wildcard |
lookup |
HashMap |
generator |
(cycleName : string | number | Wildcard ) => Wildcard | Cycle |
• Protected
cycleLength: number
• Protected
generator: (cycleName
: string
| number
) => Wildcard
| Cycle
▸ (cycleName
): Wildcard
| Cycle
Name | Type |
---|---|
cycleName |
string | number |
• Private
nextHolder: null
| Cycle
A cache of the next object in the cycle
• position: number
Absolute position within the linear cycle for this object.
• Protected
value: any
▸ isWildcard(): boolean
boolean
▸ next(): Cycle
Return the next object in the cycle
▸ Private
nextCalculator(): Cycle
▸ shift(incremental
): Cycle
Move an incremental number of steps in the cycle, and return the object found there.
Name | Type | Description |
---|---|---|
incremental |
number |
The number of steps to move through in the cycle. |
▸ toString(): string
Render this cycle object as a string
string
▸ Abstract
validate(): boolean
boolean