Create wt-odlux directory
[ccsdk/features.git] / sdnr / wt-odlux / odlux / apps / mediatorApp / src / models / mediatorServer.ts
1 /**
2  * ============LICENSE_START========================================================================
3  * ONAP : ccsdk feature sdnr wt odlux
4  * =================================================================================================
5  * Copyright (C) 2019 highstreet technologies GmbH Intellectual Property. All rights reserved.
6  * =================================================================================================
7  * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
8  * in compliance with the License. You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software distributed under the License
13  * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
14  * or implied. See the License for the specific language governing permissions and limitations under
15  * the License.
16  * ============LICENSE_END==========================================================================
17  */
18 export type MediatorServer = {
19    id: string;
20    name: string;
21    url: string;
22
23
24 export type XmlFileInfo = {
25    filename: string;
26    version: string;
27
28
29 export type MediatorServerVersionInfo = {
30    mediator: string;
31    server: string;
32    nexmls: XmlFileInfo[]; 
33
34
35 export type ODLConfig = {
36    User: string;
37    Password: string;
38    Port: number;
39    Protocol: "http" | "https";
40    Server: string;
41    Trustall: boolean;
42 }; 
43
44 export const BusySymbol = Symbol("Busy");
45
46 export type MediatorConfig = {
47    Name: string;
48    DeviceIp: string;
49    DevicePort: number;
50    DeviceType: number;
51    TrapPort: number;
52    NcUsername: string;
53    NcPassword: string;
54    NcPort: number;
55    NeXMLFile: string;
56    ODLConfig: ODLConfig[];
57 }
58
59 export type MediatorConfigResponse = MediatorConfig & {
60    IsNCConnected: boolean;
61    IsNeConnected: boolean;
62    autorun: boolean;
63    fwactive: boolean;
64    islocked: boolean;
65    ncconnections:{}[];
66    pid: number;
67    // extended properties
68    [BusySymbol]: boolean;
69
70
71 export type MediatorServerDevice = {
72   id: number;       // DeviceType
73   device: string; 
74   vendor: string;
75   version: string;
76   xml: string;      // NeXMLFile
77 }