@synerty/vortexjs
Version:
Custom observable data serialisation and routing based on Angular 2+
25 lines (24 loc) • 916 B
TypeScript
import { IPayloadFilt } from "./Payload";
import "./UtilArray";
import { NgLifeCycleEvents } from "../util/NgLifeCycleEvents";
import { Observable } from "rxjs";
import { PayloadEnvelope } from "./PayloadEnvelope";
export declare class PayloadEndpoint {
private _filt;
private _lastPayloadDate;
private _processLatestOnly;
constructor(component: NgLifeCycleEvents, filter: IPayloadFilt, processLatestOnly?: boolean);
private _observable;
get observable(): Observable<PayloadEnvelope>;
/**
* Process Payload
* Check if the payload is meant for us then process it.
*
* @return null, or if the function is overloaded, you could return STOP_PROCESSING
* from PayloadIO, which will tell it to stop processing further endpoints.
*/
process(payloadEnvelope: PayloadEnvelope): null | string;
shutdown(): void;
private checkFilt;
private checkDate;
}