bank

package
v5.2.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 21, 2021 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var KindACCOUNT = r.RegisterKind(&Account{}, "")

KindACCOUNT stores the entity kind associated with 'Account' entities

Functions

This section is empty.

Types

type Account

type Account struct {
	r.Entity         // is a particular kind of REST entity
	Balance  float64 `db:"balance,8.2" json:"balance" desc:"the bank account's balace"`
}

Account defines the structure of a ????, i.e. properties & links, plus basic methods

func NewAccount

func NewAccount(initialBalance float64) *Account

NewAccount is a shortcut to instantiate a new NewAccount

func (*Account) InitSchema

func (Account *Account) InitSchema() *r.EntitySchema

InitSchema is used to create a schema, to bear all the meta information about this entity type

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL