vntl
This commit is contained in:
parent
63cdf43bb6
commit
1c4268dd81
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -1,3 +1,4 @@
|
||||||
|
.idea/
|
||||||
node_modules/
|
node_modules/
|
||||||
dist/
|
dist/
|
||||||
**/.vs
|
**/.vs
|
||||||
|
|
16
src/ts/noauthprobe/api/model/NoAuthProbe.ts
Normal file
16
src/ts/noauthprobe/api/model/NoAuthProbe.ts
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
import Probe from '../../../probe/api/model/Probe';
|
||||||
|
|
||||||
|
interface NoAuthProbe {
|
||||||
|
id?: number;
|
||||||
|
hostName?: string;
|
||||||
|
macAddress: number;
|
||||||
|
ipAddress: number;
|
||||||
|
status: MetaNoAuthProbeStatus;
|
||||||
|
tempProbeKey: string;
|
||||||
|
createDate?: Date;
|
||||||
|
apiKey: string;
|
||||||
|
domain?: Domain;
|
||||||
|
probe: Probe;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default NoAuthProbe;
|
25
src/ts/noauthprobe/api/service/NoAuthProbeService.ts
Normal file
25
src/ts/noauthprobe/api/service/NoAuthProbeService.ts
Normal file
|
@ -0,0 +1,25 @@
|
||||||
|
import Service from 'commons/api/Service';
|
||||||
|
import NoAuthProbe from '../model/NoAuthProbe';
|
||||||
|
import Domain from '../../../domain/api/model/Domain';
|
||||||
|
|
||||||
|
export class NoAuthProbeService extends Service {
|
||||||
|
|
||||||
|
public constructor() {
|
||||||
|
super('NoAuthProbeService');
|
||||||
|
}
|
||||||
|
|
||||||
|
public regist(noAuthProbe:NoAuthProbe): void {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Todo List<NoAuthProbe>
|
||||||
|
public readAllBySensor(domain:Domain): Promise<NoAuthProbe> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public read(id:string): Promise<NoAuthProbe> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default NoAuthProbeService;
|
16
src/ts/probe/api/model/Probe.ts
Normal file
16
src/ts/probe/api/model/Probe.ts
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
import MetaProbeStatus from '../../../meta/api/model/MetaProbeStatus';
|
||||||
|
import Domain from '../../../domain/api/model/Domain';
|
||||||
|
|
||||||
|
interface Probe {
|
||||||
|
id?: number;
|
||||||
|
status: MetaProbeStatus;
|
||||||
|
description: string;
|
||||||
|
createDate?: Date;
|
||||||
|
lastPollingDate?: Date;
|
||||||
|
nextPollingDate?: Date;
|
||||||
|
domain?: Domain;
|
||||||
|
probeKey: string;
|
||||||
|
encryptionKey: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Probe;
|
16
src/ts/probe/api/model/ProbeTask.ts
Normal file
16
src/ts/probe/api/model/ProbeTask.ts
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
import Probe from './Probe';
|
||||||
|
import MetaProbeTaskType from '../../../meta/api/model/MetaProbeTaskType';
|
||||||
|
|
||||||
|
interface ProbeTask {
|
||||||
|
id?: number;
|
||||||
|
metaProbeTaskType: MetaProbeTaskType;
|
||||||
|
probe: Probe;
|
||||||
|
data: string;
|
||||||
|
createDate?: Date;
|
||||||
|
sendDate?: Date;
|
||||||
|
startDate?: Date;
|
||||||
|
endDate?: Date;
|
||||||
|
succeed: boolean;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default ProbeTask;
|
19
src/ts/probe/api/service/ProbeService.ts
Normal file
19
src/ts/probe/api/service/ProbeService.ts
Normal file
|
@ -0,0 +1,19 @@
|
||||||
|
import Service from 'commons/api/Service';
|
||||||
|
import Probe from '../model/Probe';
|
||||||
|
|
||||||
|
export class ProbeService extends Service {
|
||||||
|
|
||||||
|
public constructor() {
|
||||||
|
super('ProbeService');
|
||||||
|
}
|
||||||
|
|
||||||
|
public regist(probe:Probe): void {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public remove(probeKey:string): Promise<Probe> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default ProbeService;
|
21
src/ts/probe/api/service/ProbeTaskService.ts
Normal file
21
src/ts/probe/api/service/ProbeTaskService.ts
Normal file
|
@ -0,0 +1,21 @@
|
||||||
|
import Service from 'commons/api/Service';
|
||||||
|
import ProbeTask from '../model/ProbeTask';
|
||||||
|
import Probe from '../model/Probe';
|
||||||
|
|
||||||
|
export class ProbeTaskService extends Service {
|
||||||
|
|
||||||
|
public constructor() {
|
||||||
|
super('ProbeService');
|
||||||
|
}
|
||||||
|
|
||||||
|
public regist(probeTask:ProbeTask): void {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Todo List<ProbeTask>
|
||||||
|
public readAllByProbe(probe:Probe): Promise<ProbeTask> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default ProbeTaskService;
|
15
src/ts/sensor/api/model/Sensor.ts
Normal file
15
src/ts/sensor/api/model/Sensor.ts
Normal file
|
@ -0,0 +1,15 @@
|
||||||
|
import Target from '../../../target/api/model/Target';
|
||||||
|
import MetaSensorStatus from '../../../meta/api/model/MetaSensorStatus';
|
||||||
|
import MetaCrawler from '../../../meta/api/model/MetaCrawler';
|
||||||
|
|
||||||
|
interface Sensor {
|
||||||
|
id?: number;
|
||||||
|
createDate?: Date;
|
||||||
|
description: string;
|
||||||
|
status: MetaSensorStatus;
|
||||||
|
target: Target;
|
||||||
|
crawler: MetaCrawler;
|
||||||
|
crawlerInputItems: string;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Sensor;
|
11
src/ts/sensor/api/model/SensorItem.ts
Normal file
11
src/ts/sensor/api/model/SensorItem.ts
Normal file
|
@ -0,0 +1,11 @@
|
||||||
|
import Sensor from './Sensor';
|
||||||
|
import MetaSensorItem from '../../../meta/api/model/MetaSensorItem';
|
||||||
|
|
||||||
|
interface SensorItem {
|
||||||
|
id?: number;
|
||||||
|
sensor: Sensor;
|
||||||
|
item: MetaSensorItem;
|
||||||
|
createDate?: Date;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default SensorItem;
|
29
src/ts/sensor/api/service/SensorItemService.ts
Normal file
29
src/ts/sensor/api/service/SensorItemService.ts
Normal file
|
@ -0,0 +1,29 @@
|
||||||
|
import Service from 'commons/api/Service';
|
||||||
|
import SensorItem from '../model/SensorItem';
|
||||||
|
import Sensor from '../model/Sensor';
|
||||||
|
|
||||||
|
export class SensorItemService extends Service {
|
||||||
|
|
||||||
|
public constructor() {
|
||||||
|
super('SensorItemService');
|
||||||
|
}
|
||||||
|
|
||||||
|
public regist(sensorItem:SensorItem): Promise<SensorItem> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Todo List<SensorItem>
|
||||||
|
public readAllBySensor(sensor:Sensor): Promise<SensorItem> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public read(id:string): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public remove(sensorItem:SensorItem): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default SensorItemService;
|
38
src/ts/sensor/api/service/SensorService.ts
Normal file
38
src/ts/sensor/api/service/SensorService.ts
Normal file
|
@ -0,0 +1,38 @@
|
||||||
|
|
||||||
|
import Service from 'commons/api/Service';
|
||||||
|
import Sensor from '../model/Sensor';
|
||||||
|
import Target from '../../../target/api/model/Target';
|
||||||
|
|
||||||
|
export class SensorService extends Service {
|
||||||
|
|
||||||
|
public constructor() {
|
||||||
|
super('SensorService');
|
||||||
|
}
|
||||||
|
|
||||||
|
public regist(sensor:Sensor): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Todo List<Sensor>
|
||||||
|
public readAllByTarget(target:Target): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public read(id:string): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public remove(sensor:Sensor): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public start(sensor:Sensor): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public stop(sensor:Sensor): Promise<Sensor> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default SensorService;
|
13
src/ts/target/api/model/Target.ts
Normal file
13
src/ts/target/api/model/Target.ts
Normal file
|
@ -0,0 +1,13 @@
|
||||||
|
import Probe from '../../../probe/api/model/Probe';
|
||||||
|
import Infra from '../../../infra/api/model/Infra';
|
||||||
|
|
||||||
|
interface Target {
|
||||||
|
id?: number;
|
||||||
|
createDate?: Date;
|
||||||
|
probe: Probe;
|
||||||
|
infra: Infra;
|
||||||
|
}
|
||||||
|
|
||||||
|
export default Target;
|
||||||
|
|
||||||
|
|
17
src/ts/target/api/service/TargetDiscoveryService.ts
Normal file
17
src/ts/target/api/service/TargetDiscoveryService.ts
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
import Service from 'commons/api/Service';
|
||||||
|
import Probe from '../../../probe/api/model/Probe';
|
||||||
|
|
||||||
|
export class TargetService extends Service {
|
||||||
|
public constructor() {
|
||||||
|
super('TargetService');
|
||||||
|
}
|
||||||
|
|
||||||
|
// Todo List<Host>
|
||||||
|
public remove(host:Host, probe:Probe): void {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default TargetService;
|
||||||
|
|
||||||
|
|
36
src/ts/target/api/service/TargetService.ts
Normal file
36
src/ts/target/api/service/TargetService.ts
Normal file
|
@ -0,0 +1,36 @@
|
||||||
|
import Service from 'commons/api/Service';
|
||||||
|
import Target from '../model/Target';
|
||||||
|
import Probe from '../../../probe/api/model/Probe';
|
||||||
|
|
||||||
|
export class TargetService extends Service {
|
||||||
|
|
||||||
|
public constructor() {
|
||||||
|
super('TargetService');
|
||||||
|
}
|
||||||
|
|
||||||
|
public regist(target: Target): Promise<Target> {
|
||||||
|
return new Promise<Target>(resolve => {
|
||||||
|
const json = this.send('regist', target);
|
||||||
|
let tempTarget: Target;
|
||||||
|
|
||||||
|
resolve(tempTarget);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
public read(id:string): Promise<Target> {
|
||||||
|
return new Promise<Target>(resolve => {
|
||||||
|
resolve(null);
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
public readByProbe(probe:Probe): Promise<Target> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
|
||||||
|
public remove(target:Target): Promise<Target> {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default TargetService;
|
||||||
|
|
Loading…
Reference in New Issue
Block a user