declare namespace Leaf { interface PropertyDefination { get?: (cache: PropertyCache) => T; set?: (value: T, cache: PropertyCache) => void; value?: T; } interface PropertyCache { [index: string]: any; value?: T; } class Property { static define(who: any, name: string, def: PropertyDefination): T; static with(who: any): WithProperty<{}>; } class WithProperty { who: any; constructor(who: any); define(name: string, def: PropertyDefination): this; } }