Options
All
  • Public
  • Public/Protected
  • All
Menu

Class Configuration

Hierarchy

  • Configuration

Index

Constructors

constructor

Properties

Private sectionMap

sectionMap: SectionMap = {}

Methods

getAmount

  • Parameters

    • section: string
    • option: string

    Returns ConfigValue<AmountJson>

getNumber

  • getNumber(section: string, option: string): ConfigValue<number>
  • Parameters

    • section: string
    • option: string

    Returns ConfigValue<number>

getPath

  • getPath(section: string, option: string): ConfigValue<string>
  • Parameters

    • section: string
    • option: string

    Returns ConfigValue<string>

getSectionNames

  • getSectionNames(): string[]
  • Get lower-cased section names.

    Returns string[]

getString

  • getString(section: string, option: string): ConfigValue<string>
  • Parameters

    • section: string
    • option: string

    Returns ConfigValue<string>

getYesNo

  • getYesNo(section: string, option: string): ConfigValue<boolean>
  • Parameters

    • section: string
    • option: string

    Returns ConfigValue<boolean>

loadFromString

  • loadFromString(s: string): void
  • Parameters

    • s: string

    Returns void

lookupVariable

  • lookupVariable(x: string, depth?: number): undefined | string
  • Parameters

    • x: string
    • depth: number = 0

    Returns undefined | string

setString

  • setString(section: string, option: string, value: string): void
  • Parameters

    • section: string
    • option: string
    • value: string

    Returns void

write

  • write(filename: string): void
  • Parameters

    • filename: string

    Returns void

Static load

  • Parameters

    • filename: string

    Returns Configuration

Generated using TypeDoc