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.sdc.vendorsoftwareproduct.dao.type;
23 import com.datastax.driver.mapping.annotations.ClusteringColumn;
24 import com.datastax.driver.mapping.annotations.Column;
25 import com.datastax.driver.mapping.annotations.Frozen;
26 import com.datastax.driver.mapping.annotations.PartitionKey;
27 import com.datastax.driver.mapping.annotations.Table;
28 import org.openecomp.sdc.versioning.dao.types.Version;
29 import org.openecomp.sdc.versioning.dao.types.VersionableEntity;
31 import java.nio.ByteBuffer;
33 @Table(keyspace = "dox", name = "vsp_process")
34 public class ProcessArtifactEntity implements VersionableEntity {
35 public static final String ENTITY_TYPE = "Vendor Software Product Process artifact";
37 @Column(name = "vsp_id")
39 @PartitionKey(value = 1)
41 private Version version;
43 @Column(name = "component_id")
44 private String componentId;
45 @ClusteringColumn(value = 1)
46 @Column(name = "process_id")
48 @Column(name = "artifact_name")
49 private String artifactName;
50 private ByteBuffer artifact;
52 public ProcessArtifactEntity() {
57 * Instantiates a new Process artifact entity.
59 * @param vspId the vsp id
60 * @param version the version
61 * @param componentId the component id
64 public ProcessArtifactEntity(String vspId, Version version, String componentId, String id) {
66 this.version = version;
67 this.componentId = componentId;
71 public String getVspId() {
75 public void setVspId(String vspId) {
79 public Version getVersion() {
83 public void setVersion(Version version) {
84 this.version = version;
87 public String getComponentId() {
91 public void setComponentId(String componentId) {
92 this.componentId = componentId;
96 public String getEntityType() {
101 public String getFirstClassCitizenId() {
105 public String getId() {
109 public void setId(String id) {
113 public String getArtifactName() {
117 public void setArtifactName(String artifactName) {
118 this.artifactName = artifactName;
121 public ByteBuffer getArtifact() {
125 public void setArtifact(ByteBuffer artifact) {
126 this.artifact = artifact;