import * as express from 'express'; import { TxRouteApplication } from './tx-route-application'; import { TxRouteService } from './tx-route-service'; import { TxRouteServiceConfig } from './tx-route-service-config'; import { TxRouteServiceTask } from './tx-route-service-task'; import { TxRouteServiceExpress } from './tx-route-service-express'; import { TxTask } from './tx-task'; export declare class TxRouteServiceExpressGet extends TxRouteServiceExpress implements TxRouteService { private cname; constructor(application: TxRouteApplication, config: TxRouteServiceConfig); /** * this method is called by TxRouteApplication app wrapper druing TxRoutePointRegistry.instance.setApplication(app) method * * @param config is the rooutepoint config object as user define on TxRoutePointRegistry.instance.route(..) */ add(config: TxRouteServiceConfig): express.Router; /** * Use to send reply back to client use express response object. * This trigger by task.reply().next(..) * * The task body in the format of: * { * headers: { * source: 'back-application-main', * token: '123456780ABCDEF' * }, * response: { * status: 200, * type: 'json' * }}, * { * source: 'back-application-main', status: "ok" * } * } * * @param from a task coming from the express.Route API, implement in this,add method * @param task a task from subscriber need to reply it back client using response */ send(from: TxRouteServiceTask, task: TxRouteServiceTask): void; unsubscribe(): void; /** * client side: use to send request to service using axios * * @param task - tast need to send to service */ next(task: TxTask): Promise>; /** * @deprecated - use URL.parse * @param base * @param task */ buildUrl(base: string, task: TxTask): string; prefix(method: string): string; } export default TxRouteServiceExpressGet;