UNPKG

class-o-mat

Version:

ALPHA VERSION ONLY: class-o-mats will help to create getter-setter functionality with validations that can be attached to a container class for easier coding. Some basic validations are included. class-o-mats also has the ability to store params as bloc

23 lines (17 loc) 327 B
import Bunyan from 'bunyan'; const log = Bunyan.createLogger({name: "AutonumGenerator"}); class AutonumGenerator { constructor( ) { this._count = 0; } count() { return this._count; } last() { return this._count-1; } next() { return this._count++; } } export default AutonumGenerator;