Last active
November 20, 2015 21:19
-
-
Save samueleresca/589b0f440e1a84d0ba66 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Ticket { | |
private _id: string; | |
private _enterDate: Date; | |
private _exitDate: Date; | |
constructor(parking_lot: string) { | |
this._id = parking_lot + "-" + ((new Date()).getTime().toString()); | |
this._enterDate = new Date(); //GET CURRENT DATE | |
this._exitDate = null; | |
} | |
get Id() { return this._id; } | |
get EnterDate() { return this._enterDate; } | |
set EnterDate(date: Date) { this._enterDate = date; } | |
get ExitDate() { return this._exitDate; } | |
set ExitDate(date: Date) { this._exitDate = date; } | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment