import * as Attributes from "./Attributes" ; export enum SizeType { Absolute , Relative } export class Size { @ Attributes . enumLiterals ( SizeType ) type : SizeType ; value : number ; constructor ( type ? , value ? ) { this . type = type !== undefined ? type : SizeType . Relative ; this . value = value || ( this . type === SizeType . Relative ? 1 : 1024 ) ; } equals ( other ) { return this . value === other . value && this . type === other . type ; } } hidden export interface SerializedSize { type : number ; value : number ; }