2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 - 2019 AT&T Intellectual Property. All rights reserved.
6 * ================================================================================
7 * Licensed under the Apache License, Version 2.0 (the "License");
8 * you may not use this file except in compliance with the License.
9 * You may obtain a copy of the License at
11 * http://www.apache.org/licenses/LICENSE-2.0
13 * Unless required by applicable law or agreed to in writing, software
14 * distributed under the License is distributed on an "AS IS" BASIS,
15 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16 * See the License for the specific language governing permissions and
17 * limitations under the License.
18 * ============LICENSE_END=========================================================
21 package org.onap.vid.model.aaiTree;
23 import org.onap.vid.aai.util.AAITreeConverter;
25 import static org.onap.vid.aai.util.AAITreeConverter.IS_BASE_VF_MODULE;
27 public class VfModule extends Node {
29 private boolean isBase;
30 private String volumeGroupName;
32 public VfModule(AAITreeNode node) {
33 super(node, AAITreeConverter.ModelType.vfModule);
36 public boolean getIsBase() {
40 public void setIsBase(boolean isBase) {
44 public String getVolumeGroupName() {
45 return volumeGroupName;
48 public void setVolumeGroupName(String volumeGroupName) {
49 this.volumeGroupName = volumeGroupName;
52 public static VfModule from(AAITreeNode node) {
53 VfModule vfModule = new VfModule(node);
55 if (node.getAdditionalProperties().get(IS_BASE_VF_MODULE) != null) {
56 vfModule.setIsBase(Boolean.valueOf(node.getAdditionalProperties().get(IS_BASE_VF_MODULE).toString()));