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=========================================================
21 package org.openecomp.mso.db.catalog.beans;
24 import java.sql.Timestamp;
25 import java.text.DateFormat;
27 import org.openecomp.mso.db.catalog.utils.MavenLikeVersioning;
29 public class HeatFiles extends MavenLikeVersioning {
31 private String description = null;
32 private String fileName;
33 private String fileBody;
34 private int vnfResourceId;
35 private Timestamp created;
36 private String asdcUuid;
37 private String asdcLabel;
38 private String asdcResourceName;
46 public void setId(int id) {
50 public String getDescription() {
51 return this.description;
53 public void setDescription(String description) {
54 this.description = description;
57 public String getFileName() {
60 public void setFileName(String fileName) {
61 this.fileName = fileName;
64 public String getFileBody() {
67 public void setFileBody(String fileBody) {
68 this.fileBody = fileBody;
71 public int getVnfResourceId() {
72 return this.vnfResourceId;
74 public void setVnfResourceId(int vnfResourceId) {
75 this.vnfResourceId = vnfResourceId;
78 public Timestamp getCreated() {
82 public void setCreated(Timestamp created) {
83 this.created = created;
86 public String getAsdcUuid() {
89 public void setAsdcUuid(String asdcUuid) {
90 this.asdcUuid = asdcUuid;
92 public String getAsdcLabel() {
93 return this.asdcLabel;
95 public void setAsdcLabel(String asdcLabel) {
96 this.asdcLabel = asdcLabel;
98 public String getAsdcResourceName() {
99 return asdcResourceName;
102 public void setAsdcResourceName(String asdcResourceName) {
103 this.asdcResourceName = asdcResourceName;
107 public String toString () {
108 StringBuffer sb = new StringBuffer();
109 sb.append ("ID=" + this.id);
110 if (this.description == null) {
111 sb.append(", description=null");
113 sb.append(", description=" + this.description);
115 if (this.fileName == null) {
116 sb.append(", fileName=null");
118 sb.append(",fileName=" + this.fileName);
120 if (this.fileBody == null) {
121 sb.append(", fileBody=null");
123 sb.append(",fileBody=" + this.fileBody);
125 if (this.asdcResourceName == null) {
126 sb.append(", asdcResourceName=null");
128 sb.append(",asdcResourceName=" + this.asdcResourceName);
130 if (created != null) {
131 sb.append (",created=");
132 sb.append (DateFormat.getInstance().format(created));
134 sb.append(", vnfResourceId=" + this.vnfResourceId);
135 return sb.toString();