Feature 10914: Enforce Password change on First login
[osm/NG-UI.git] / src / models / VNFDModel.ts
1 /*
2  Copyright 2020 TATA ELXSI
3
4  Licensed under the Apache License, Version 2.0 (the 'License');
5  you may not use this file except in compliance with the License.
6  You may obtain a copy of the License at
7
8     http://www.apache.org/licenses/LICENSE-2.0
9
10  Unless required by applicable law or agreed to in writing, software
11  distributed under the License is distributed on an "AS IS" BASIS,
12  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  See the License for the specific language governing permissions and
14  limitations under the License.
15
16  Author: KUMARAN M (kumaran.m@tataelxsi.co.in), RAJESH S (rajesh.s@tataelxsi.co.in), BARATH KUMAR R (barath.r@tataelxsi.co.in)
17  */
18 /**
19  * @file  Model for VNFD related information.
20  */
21 // tslint:disable: completed-docs
22 /** Interface for Project */
23 export interface ProjectModel {
24     project_id: string;
25     project?: string;
26     project_name?: string;
27     expires: number;
28     _id: string;
29     id: string;
30     issued_at: number;
31     remote_port: number;
32     username: string;
33     remote_host: string;
34     admin: boolean;
35     message?: string;
36     user_id?: string;
37 }
38
39 /** Interface for ProjectDetails */
40 export interface ProjectDetails {
41     _admin: AdminDetails;
42     name: string;
43     _id: string;
44 }
45
46 /** Interface for AdminDetails */
47 interface AdminDetails {
48     modified: string;
49     created: string;
50 }
51
52 /** Interface for VNFD Details */
53 export interface VNFD {
54     description?: string;
55     df?: DF[];
56     'ext-cpd'?: EXTCPD[];
57     id: string;
58     'int-virtual-link-desc'?: IVLD[];
59     'mgmt-cp'?: string;
60     onboardingState?: string;
61     operationalState?: string;
62     'product-name'?: string;
63     provider?: string;
64     'sw-image-desc'?: SWIMAGEDESCRIPTION[];
65     usageState?: string;
66     vdu?: VDU[];
67     version?: string;
68     'virtual-compute-desc'?: string;
69     'virtual-storage-desc'?: string[];
70     _admin?: VNFDAdminDetails;
71     _id?: string;
72     _links?: string;
73     'vnf-configuration'?: VNFCONFIG[];
74     kdu?: [];
75 }
76 /** Interface for DF */
77 export interface VNFCONFIG {
78     id: string;
79     'config-primitive'?: CONFIGPRIMITIVE[];
80     'initial-config-primitive'?: INITIALCONFIGPRIMITIVE[];
81 }
82 /** Interface for DF */
83 export interface DF {
84     id: string;
85     'instantiation-level'?: INSTANTIATIONLEVEL[];
86     'vdu-profile'?: VDUPROFILE[];
87     'vnf-configuration-id'?: string;
88     'scaling-aspect'?: SCALING[];
89 }
90 /** Interface for INSTANTIATIONLEVEL */
91 export interface INSTANTIATIONLEVEL {
92     id: string;
93     'vdu-level': VDULEVEL[];
94 }
95 /** Interface for VDULEVEL */
96 export interface VDULEVEL {
97     'number-of-instances': number;
98     'vdu-id': string;
99 }
100 /** Interface for VDULEVEL */
101 export interface VDUPROFILE {
102     id: string;
103     name?: string;
104     'min-number-of-instances'?: number;
105     'max-number-of-instances'?: number;
106     'vdu-configuration-id'?: string;
107     'vdu-configuration'?: VDUCONFIG;
108 }
109 /** Interface for SCALING */
110 export interface SCALING {
111     'aspect-delta-details'?: object;
112     id: string;
113     name?: string;
114     'max-scale-level'?: number;
115     'scaling-policy'?: SCALINGPOLICY[];
116 }
117 /** Interface for SCALINGPOLICY */
118 export interface SCALINGPOLICY {
119     'cooldown-time': number;
120     name?: string;
121     'scaling-criteria': SCALINGCRITERIA[];
122     'scaling-type'?: string;
123     'threshold-time'?: number;
124 }
125 /** Interface for SCALINGCRITERIA */
126 export interface SCALINGCRITERIA {
127     name?: string;
128     'scale-in-relational-operation': string;
129     'scale-in-threshold'?: string;
130     'scale-out-relational-operation'?: string;
131     'scale-out-threshold'?: string;
132     'vnf-monitoring-param-ref'?: string;
133 }
134 /** Interface for VDUCONFIG */
135 export interface VDUCONFIG {
136     id: string;
137     'config-primitive': CONFIGPRIMITIVE[];
138     'initial-config-primitive': INITIALCONFIGPRIMITIVE[];
139 }
140 /** Interface for CONFIGPRIMITIVE */
141 export interface CONFIGPRIMITIVE {
142     name: string;
143 }
144 /** Interface for INITIALCONFIGPRIMITIVE */
145 export interface INITIALCONFIGPRIMITIVE {
146     seq: string;
147     name: string;
148 }
149 /** Interface for the ext-cpd */
150 export interface EXTCPD {
151     id?: string;
152     'int-cpd'?: INTCPD;
153 }
154 /** Interface for the int-cpd */
155 export interface INTCPD {
156     cpd?: string;
157     'vdu-id'?: string;
158 }
159 /** Interface for IVLD */
160 export interface IVLD {
161     id?: string;
162     description?: string;
163 }
164 /** Interface for SWIMAGEDESCRIPTION */
165 export interface SWIMAGEDESCRIPTION {
166     id: string;
167     name: string;
168     version: string;
169 }
170 /** Interface for VDU */
171 export interface VDU {
172     'cloud-init-file'?: string;
173     description?: string;
174     id?: string;
175     'int-cpd'?: VDUINTCPD[];
176     'monitoring-parameter'?: MonitoringParam[];
177     name?: string;
178     'sw-image-desc'?: string;
179     'virtual-compute-desc'?: string;
180     'virtual-storage-desc'?: string[];
181 }
182 /** Interface for the vdu int-cpd */
183 export interface VDUINTCPD {
184     id: string;
185     'int-virtual-link-desc'?: string;
186     'virtual-network-interface-requirement': VNIR[];
187 }
188 /** Interface for the vdu int-cpd => VNIR */
189 export interface VNIR {
190     name: string;
191     position: number;
192     'virtual-interface': VIRTUALINTERFACE;
193 }
194 /** Interface for the VIRTUALINTERFACE */
195 export interface VIRTUALINTERFACE {
196     'type': string;
197 }
198 /** Interface for monitoring params */
199 export interface MonitoringParam {
200     id: string;
201     name?: string;
202     'performance-metric'?: string;
203     'collection-period'?: number;
204 }
205 /** Interface for VNFDATA */
206 export interface VNFDATA {
207     vnfd?: VNFD;
208 }
209
210 /** Interface for VDU InternalCPD */
211 export interface InternalCPD {
212     id: string;
213     'int-virtual-link-desc'?: string;
214     'virtual-network-interface-requirement'?: VIRTUALNETWORKINTERFACEREQUIREMENT;
215 }
216
217 /** Interface for VIRTUALNETWORKINTERFACEREQUIREMENT */
218 export interface VIRTUALNETWORKINTERFACEREQUIREMENT {
219     name: string;
220     position?: number;
221     'virtual-interface'?: VirtualInterface;
222 }
223
224 /** Interface for VirutalInterface */
225 interface VirtualInterface {
226     'type': string;
227 }
228
229 /** Interface for _AdminDetails */
230 export interface VNFDAdminDetails {
231     created: number;
232     modified: string;
233     onboardingState: string;
234     operationalState: string;
235     projects_read: string[];
236     projects_write: string[];
237     storage: Storage;
238     'type': string;
239     usageState: string;
240     userDefinedData: JSON;
241 }
242
243 /** Interface for Storage */
244 interface Storage {
245     descriptor: string;
246     folder: string;
247     fs: string;
248     path: string;
249     'pkg-dir': string;
250     zipfile: string;
251 }
252
253 /** Interface for VNFData */
254 export interface VNFData {
255     identifier?: string;
256     id?: string;
257     name?: string;
258     description: string;
259     version: string;
260     'type'?: string;
261     productName?: string;
262     provider?: string;
263 }
264
265 /** Interface for the Tick */
266 export interface Tick {
267     target: TickPath;
268     source: TickPath;
269     left: boolean;
270     right: boolean;
271 }
272
273 /** Interface for the Path */
274 export interface TickPath {
275     x: number;
276     y: number;
277     id: string;
278     'type'?: string;
279 }
280
281 /** Interface Nodes Creation */
282 export interface COMPOSERNODES {
283     id: string;
284     reflexive: Boolean;
285     'type': string;
286     name?: string;
287     nodeIndex?: number;
288     selectorId?: string;
289     x?: number;
290     y?: number;
291     fx?: number;
292     fy?: number;
293 }
294
295 /** Interface for the GRAPHDETAILS */
296 export interface GRAPHDETAILS {
297     width: number;
298     height: number;
299     nodeHeight: number;
300     nodeWidth: number;
301     textX: number;
302     textY: number;
303     radius: number;
304     distance: number;
305     strength: number;
306     forcex: number;
307     forcey: number;
308     sourcePaddingYes: number;
309     sourcePaddingNo: number;
310     targetPaddingYes: number;
311     targetPaddingNo: number;
312     alphaTarget: number;
313     imageX: number;
314     imageY: number;
315     shiftKeyCode: number;
316 }