import { ClientConfig, Message, PublishOptions, PubSub, SubscriberOptions, Subscription } from '@google-cloud/pubsub'; import { CustomTransportStrategy, Server } from '@nestjs/microservices'; import { Logger } from '@nestjs/common'; import { GCPubSubOptions } from './gc-pubsub.interface'; import { GCPubSubEvents } from './gc-pubsub.events'; export declare class GCPubSubServer extends Server implements CustomTransportStrategy { protected readonly options: GCPubSubOptions; protected logger: Logger; protected readonly clientConfig: ClientConfig; protected readonly topicName: string; protected readonly publisherConfig: PublishOptions; protected readonly subscriptionName: string; protected readonly subscriberConfig: SubscriberOptions; protected readonly noAck: boolean; protected readonly replyTopics: Set; protected readonly init: boolean; protected readonly checkExistence: boolean; protected readonly scopedEnvKey: string | null; protected readonly subscriptionFilter: string | undefined; protected pendingEventListeners: Array<{ event: keyof GCPubSubEvents; callback: GCPubSubEvents[keyof GCPubSubEvents]; }>; protected client: PubSub | null; protected subscription: Subscription | null; constructor(options: GCPubSubOptions); listen(callback: () => void): Promise; close(): Promise; handleMessage(message: Message): Promise; sendMessage(message: T, replyTo: string, id: string): Promise; createIfNotExists(create: () => Promise): Promise; createClient(): PubSub; on(event: EventKey, callback: EventCallback): void; unwrap(): T; }