Options
All
  • Public
  • Public/Protected
  • All
Menu

Class SavingsAccount

Class representing a SavingsAccount

Hierarchy

Index

Constructors

constructor

Properties

Protected _balance

_balance: number = 0

The balance of the bank account.

Protected _holder

_holder: Person

The holder of the bank account.

Private _lastWithdrawal

_lastWithdrawal: Date

accountNumber

accountNumber: string

The account number of the bank account.

Accessors

balance

  • get balance(): number

holder

lastWithdrawal

  • get lastWithdrawal(): Date

Methods

applyInterests

  • applyInterests(): void

deposit

  • deposit(amount: number): void

withdrawal

  • withdrawal(amount: number): void
  • Perform withdrawal on the account

    throws

    If the withdrawal amount is negative or exceeds the authorized limit

    Parameters

    • amount: number

      The amount to withdraw

    Returns void

Generated using TypeDoc