rt-graphic-component/components/common/common.d.ts
2024-01-04 15:14:25 +08:00

40 lines
931 B
TypeScript

export declare enum DevicePort {
A = "A",
B = "B",
C = "C"
}
export declare enum DeviceType {
Section = 0,
Turnout = 1,
TrainWindow = 2,
AxleCounting = 3,
SectionLink = 4,
Signal = 5,
Station = 6,
ScreenDoor = 7,
SignalFaultAlarm = 8,
Breakers = 9,
PowerScreen = 10
}
export declare enum Direction {
LEFT = 0,
RIGHT = 1
}
export interface KilometerSystem {
get coordinateSystem(): string;
set coordinateSystem(v: string);
get kilometer(): number;
set kilometer(v: number);
get direction(): Direction;
set direction(v: Direction);
}
export interface IRelatedRef {
deviceType: DeviceType;
id: number;
devicePort: DevicePort;
}
export declare namespace IRelatedRef {
function create(type: string, id: number, port: DevicePort): IRelatedRef;
}
export declare function protoPort2Data(port: DevicePort): "A" | "B" | "C" | undefined;