Cleanup imports
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
import {PDU} from "../CommonObjects";
|
||||
import Logger from "../Logger";
|
||||
|
||||
export abstract class PduProcessor {
|
||||
export default abstract class PduProcessor {
|
||||
abstract readonly serverSessionType: string;
|
||||
readonly name: string = this.constructor.name;
|
||||
readonly logger: Logger = new Logger(`PduProcessor: ${this.name}`);
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import {Center} from "../../../Center/Center";
|
||||
import Center from "../../../Center/Center";
|
||||
import {PDU} from "../../../CommonObjects";
|
||||
import Postprocessor from "../Postprocessor";
|
||||
|
||||
export class DebugPduProcessor extends Postprocessor {
|
||||
export default class DebugPduProcessor extends Postprocessor {
|
||||
serverSessionType: string = Center.name;
|
||||
|
||||
processPdu(session: any, pdu: PDU, ...args: any[]): Promise<any> {
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
import {Center} from "../../../Center/Center";
|
||||
import Center from "../../../Center/Center";
|
||||
import {PDU} from "../../../CommonObjects";
|
||||
import Postprocessor from "../Postprocessor";
|
||||
|
||||
const smpp = require("smpp");
|
||||
|
||||
export class EchoPduProcessor extends Postprocessor {
|
||||
export default class EchoPduProcessor extends Postprocessor {
|
||||
serverSessionType: string = Center.name;
|
||||
|
||||
processPdu(session: any, pdu: PDU, ...args: any[]): Promise<any> {
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import {Client} from "../../../Client/Client";
|
||||
import Client from "../../../Client/Client";
|
||||
import {PDU} from "../../../CommonObjects";
|
||||
import Postprocessor from "../Postprocessor";
|
||||
|
||||
export class DeliverSmReplyProcessor extends Postprocessor {
|
||||
export default class DeliverSmReplyProcessor extends Postprocessor {
|
||||
serverSessionType: string = Client.name;
|
||||
|
||||
processPdu(session: any, pdu: PDU, ...args: any[]): Promise<any> {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import {PduProcessor} from "../PduProcessor";
|
||||
import PduProcessor from "../PduProcessor";
|
||||
|
||||
export default abstract class Postprocessor extends PduProcessor {
|
||||
readonly type: string = this.name;
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import {Client} from "../../../Client/Client";
|
||||
import Client from "../../../Client/Client";
|
||||
import {PDU} from "../../../CommonObjects";
|
||||
import Preprocessor from "../Preprocessor";
|
||||
|
||||
export class DestinationEnumeratorProcessor extends Preprocessor {
|
||||
export default class DestinationEnumeratorProcessor extends Preprocessor {
|
||||
serverSessionType: string = Client.name;
|
||||
private iterator = 0;
|
||||
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import {Client} from "../../../Client/Client";
|
||||
import Client from "../../../Client/Client";
|
||||
import {PDU} from "../../../CommonObjects";
|
||||
import Preprocessor from "../Preprocessor";
|
||||
|
||||
export class SourceEnumeratorProcessor extends Preprocessor {
|
||||
export default class SourceEnumeratorProcessor extends Preprocessor {
|
||||
serverSessionType: string = Client.name;
|
||||
private iterator = 0;
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import {PduProcessor} from "../PduProcessor";
|
||||
import PduProcessor from "../PduProcessor";
|
||||
|
||||
export default abstract class Preprocessor extends PduProcessor {
|
||||
readonly type: string = this.name;
|
||||
|
||||
@@ -1,11 +1,11 @@
|
||||
import Logger from "../Logger";
|
||||
import {SmppSession} from "../SmppSession";
|
||||
import {PduProcessor} from "./PduProcessor";
|
||||
import {DebugPduProcessor} from "./Postprocessor/Center/DebugPduProcessor";
|
||||
import {EchoPduProcessor} from "./Postprocessor/Center/EchoPduProcessor";
|
||||
import {DeliverSmReplyProcessor} from "./Postprocessor/Client/DeliverSmReplyProcessor";
|
||||
import {DestinationEnumeratorProcessor} from "./Preprocessor/Client/DestinationEnumeratorProcessor";
|
||||
import {SourceEnumeratorProcessor} from "./Preprocessor/Client/SourceEnumeratorProcessor";
|
||||
import SmppSession from "../SmppSession";
|
||||
import PduProcessor from "./PduProcessor";
|
||||
import DebugPduProcessor from "./Postprocessor/Center/DebugPduProcessor";
|
||||
import EchoPduProcessor from "./Postprocessor/Center/EchoPduProcessor";
|
||||
import DeliverSmReplyProcessor from "./Postprocessor/Client/DeliverSmReplyProcessor";
|
||||
import DestinationEnumeratorProcessor from "./Preprocessor/Client/DestinationEnumeratorProcessor";
|
||||
import SourceEnumeratorProcessor from "./Preprocessor/Client/SourceEnumeratorProcessor";
|
||||
|
||||
export default class ProcessorManager {
|
||||
static readonly preprocessors: PduProcessor[] = [
|
||||
|
||||
Reference in New Issue
Block a user