aboutsummaryrefslogtreecommitdiffstats
path: root/vid-webpack-master/src/app/shared/models/vnfModel.ts
blob: 220dc0fc5906bae70ae738907a4602429a10d1ee (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import {
  Level1Model,
  Level1ModelProperties,
  Level1ModelResponseInterface
} from "./nodeModel";
import {Utils} from "../utils/utils";

export interface VnfProperties extends Level1ModelProperties {
  ecomp_generated_naming: string;
}

export interface VNFModelResponseInterface extends Level1ModelResponseInterface {
  properties: VnfProperties;
}

export class VNFModel extends Level1Model {
  properties: VnfProperties;

  constructor(vnfJson?: VNFModelResponseInterface, flags?: { [key: string]: boolean }) {
    super(vnfJson);
    if (vnfJson) {
      this.properties = vnfJson.properties;
      this.max = Utils.getMaxFirstLevel(this.properties, flags);
    }
  }
}