2 * ============LICENSE_START=======================================================
4 * ================================================================================
5 * Copyright (C) 2017 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=========================================================
20 package org.openecomp.sdc.be.model;
22 import java.util.List;
23 import org.openecomp.sdc.be.datatypes.elements.ProductMetadataDataDefinition;
24 import org.openecomp.sdc.be.datatypes.enums.ComponentTypeEnum;
26 public class Product extends Component {
29 super(new ProductMetadataDefinition());
30 this.getComponentMetadataDefinition().getMetadataDataDefinition().setComponentType(ComponentTypeEnum.PRODUCT);
33 public Product(ProductMetadataDefinition productMetadataDefinition) {
34 super(productMetadataDefinition);
35 this.getComponentMetadataDefinition().getMetadataDataDefinition().setComponentType(ComponentTypeEnum.PRODUCT);
38 public String getFullName() {
39 return getProductMetadataDefinition().getFullName();
42 public void setFullName(String fullName) {
43 getProductMetadataDefinition().setFullName(fullName);
47 public String getInvariantUUID() {
48 return getProductMetadataDefinition().getInvariantUUID();
52 public void setInvariantUUID(String invariantUUID) {
53 getProductMetadataDefinition().setInvariantUUID(invariantUUID);
56 public List<String> getContacts() {
57 return getProductMetadataDefinition().getContacts();
60 public void setContacts(List<String> contacts) {
61 getProductMetadataDefinition().setContacts(contacts);
64 public void addContact(String contact) {
65 getProductMetadataDefinition().addContact(contact);
68 public Boolean getIsActive() {
69 return getProductMetadataDefinition().getIsActive();
72 public void setIsActive(Boolean isActive) {
73 getProductMetadataDefinition().setIsActive(isActive);
76 private ProductMetadataDataDefinition getProductMetadataDefinition() {
77 return (ProductMetadataDataDefinition) getComponentMetadataDefinition().getMetadataDataDefinition();