member_webapp/src/packages/discovery/service/target-discovery.service.ts

32 lines
766 B
TypeScript
Raw Normal View History

2018-04-06 11:02:18 +00:00
import { Injectable } from '@angular/core';
import { Observable } from 'rxjs/Observable';
import { RPCService } from '@loafer/ng-rpc/service';
import {
DiscoveryStartInfo,
2018-04-27 16:29:54 +00:00
DiscoverZone as MDDiscoverZone,
DiscoverHost as MDDiscoverHost,
DiscoverPort as MDDiscoverPort,
DiscoverService as MDDiscoverService,
2018-04-06 11:02:18 +00:00
Zone,
Host,
Port,
Service,
2018-05-02 07:23:35 +00:00
} from '@overflow/commons-typescript/model/discovery';
import { Probe } from '@overflow/commons-typescript/model/probe';
2018-04-06 11:02:18 +00:00
@Injectable()
export class TargetDiscoveryService {
public constructor(
private rpcService: RPCService,
) {
}
public saveAllTarget(hosts: Host[], probe: Probe): Observable<Boolean> {
return this.rpcService.call('TargetDiscoveryService.saveAllTarget', hosts, probe);
}
}