Options
All
  • Public
  • Public/Protected
  • All
Menu

Class ChipCollection

Basic class to represent a grouping of IChips.

Supports activities like: getting chips, adding chips, taking specific chip, taking chips by value, getting value of chips.

Hierarchy

  • ChipCollection

Implements

Index

Constructors

constructor

Methods

addChip

  • addChip(chip: IChip): this

addChips

  • addChips(chips: IChip[]): this

colorUp

getChipCount

  • getChipCount(): number

getChips

getValue

  • getValue(chips?: IChip[] | undefined): number
  • Return value of Chips currently in ChipCollection (via IChipCollection.getChips()). Optionally, can pass in IChip[] to evaluate a manually passed in value.

    Parameters

    • Optional chips: IChip[] | undefined

      Optional, value of passed in chips. If no chips passed in, it will evaluate value of current ChipCollection.

    Returns number

indexOfChip

  • indexOfChip(chip: IChip): number

isEmpty

  • isEmpty(): boolean

removeChips

setChips

  • setChips(chips: IChip[]): this

takeValue

  • takeValue(amount: number): IChip[]

Generated using TypeDoc