Files
DefinitelyTyped/pubsubjs/pubsub.d.ts
2013-06-28 22:14:33 +01:00

27 lines
606 B
TypeScript

// Type definitions for PubSubJS 1.3.5
declare module PubSubJS {
interface Base extends Publish, Subscribe, Unsubscribe {
version: string;
name: string;
}
interface Publish{
publish(message: any, data: any): bool;
publish(message:any, data:any, sync:bool, immediateExceptions:Function): bool;
publishSync(message: any, data: any): bool;
}
interface Subscribe{
subscribe(message: any, func: Function): any;
}
interface Unsubscribe{
unsubscribe(tokenOrFunction: any): any;
}
}
declare var PubSub: PubSubJS.Base;