index.d.ts 711 B

1234567891011121314
  1. import Browser, { BrowserConfig } from './lib/browser';
  2. import Service, { ServiceConfig, ServiceReferer } from './lib/service';
  3. export declare class Bonjour {
  4. private server;
  5. private registry;
  6. constructor(opts?: ServiceConfig | undefined, errorCallback?: Function | undefined);
  7. publish(opts: ServiceConfig): Service;
  8. unpublishAll(callback?: CallableFunction | undefined): void;
  9. find(opts?: BrowserConfig | undefined, onup?: (service: Service) => void): Browser;
  10. findOne(opts?: BrowserConfig | undefined, timeout?: number, callback?: CallableFunction): Browser;
  11. destroy(): void;
  12. }
  13. export { Service, ServiceReferer, ServiceConfig, Browser, BrowserConfig };
  14. export default Bonjour;