feat: add saveable thing for saving user/client data

Closes #12
This commit is contained in:
Jovan Krunić
2018-12-18 22:35:33 +01:00
parent 13a49650c4
commit a4f3fab033
2 changed files with 43 additions and 42 deletions

View File

@@ -0,0 +1,30 @@
/*
* Copyright (C) 2018, 2019 StApps
* This program is free software: you can redistribute it and/or modify it
* under the terms of the GNU General Public License as published by the Free
* Software Foundation, version 3.
*
* This program is distributed in the hope that it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License along with
* this program. If not, see <https://www.gnu.org/licenses/>.
*/
import {SCThing, SCThingUserOrigin} from '../Thing';
/**
* An encapsulation of the data (e.g. a thing) that is saved, which provides additional information.
*/
export interface SCSaveableThing<T extends SCThing> extends SCThing {
/**
* The contained data
*/
data: T;
/**
* Type of the origin
*/
origin: SCThingUserOrigin;
}