changing how assertions access instance variables to make them non-static-like (#37)

Changing how assertions access instance variables
This commit is contained in:
Sam Rang
2016-05-09 12:17:54 -05:00
committed by József Farkas
parent 864941e5ae
commit 6e218387fc
26 changed files with 112 additions and 77 deletions

View File

@@ -3,21 +3,22 @@ import {ModuleConfigurations} from './ModuleConfigurations';
import {KeyMaps} from './KeyMaps';
import {Macros} from './Macros';
import {UhkBuffer} from '../UhkBuffer';
import {assertUInt8, assertUInt32} from '../assert';
export class UhkConfiguration extends Serializable<UhkConfiguration> {
signature: string;
// @assertUInt8
@assertUInt8
dataModelVersion: number;
// @assertUInt32
@assertUInt32
prologue: number;
// @assertUInt8
@assertUInt8
hardwareId: number;
// @assertUInt8
@assertUInt8
brandId: number;
moduleConfigurations: ModuleConfigurations;
@@ -26,7 +27,7 @@ export class UhkConfiguration extends Serializable<UhkConfiguration> {
macros: Macros;
// @assertUInt32
@assertUInt32
epilogue: number;
_fromJsObject(jsObject: any): UhkConfiguration {