import { LoggingInterface } from "./logging"; import { QuerySource } from "./query"; import { DnsQueryMessage, DnsResponseMessage } from "./core/protocol"; export declare type QueryHandler = (query: DnsQueryMessage, source: QuerySource) => DnsResponseMessage | Promise; export declare type OptionalQueryHandler = (query: DnsQueryMessage, source: QuerySource) => DnsResponseMessage | Promise | undefined | void; export interface ServerOptions { name?: string; address?: string; port?: number; log?: LoggingInterface; } export declare function startUdpServer(queryHandler: QueryHandler, options?: ServerOptions): void;