badcaebe3a5b70131a582098e04b9f8326ccefd0
[music.git] / src / main / java / org / onap / music / datastore / jsonobjects / JsonTable.java
1 /*
2  * ============LICENSE_START==========================================
3  * org.onap.music
4  * ===================================================================
5  *  Copyright (c) 2017 AT&T Intellectual Property
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
10  * 
11  *     http://www.apache.org/licenses/LICENSE-2.0
12  * 
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  * 
19  * ============LICENSE_END=============================================
20  * ====================================================================
21  */
22
23 package org.onap.music.datastore.jsonobjects;
24
25 import java.util.Map;
26
27 import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
28
29 import io.swagger.annotations.ApiModel;
30 import io.swagger.annotations.ApiModelProperty;
31
32 @ApiModel(value = "JsonTable", description = "Defines the Json for Creating a new Table.")
33 @JsonIgnoreProperties(ignoreUnknown = true)
34 public class JsonTable {
35     private String keyspaceName;
36     private String tableName;
37
38     private Map<String, String> fields;
39     private Map<String, Object> properties;
40     private String primaryKey;
41     private String partitionKey;
42     private String clusteringKey;
43     private String filteringKey;
44     private String clusteringOrder;
45     private Map<String, String> consistencyInfo;
46
47     @ApiModelProperty(value = "Consistency level", allowableValues = "eventual,critical,atomic")
48     public Map<String, String> getConsistencyInfo() {
49         return consistencyInfo;
50     }
51
52     public void setConsistencyInfo(Map<String, String> consistencyInfo) {
53         this.consistencyInfo = consistencyInfo;
54     }
55
56     @ApiModelProperty(value = "Properties")
57     public Map<String, Object> getProperties() {
58         return properties;
59     }
60
61     public void setProperties(Map<String, Object> properties) {
62         this.properties = properties;
63     }
64
65     @ApiModelProperty(value = "Fields")
66     public Map<String, String> getFields() {
67         return fields;
68     }
69
70     public void setFields(Map<String, String> fields) {
71         this.fields = fields;
72     }
73
74     @ApiModelProperty(value = "KeySpace Name")
75     public String getKeyspaceName() {
76         return keyspaceName;
77     }
78
79     public void setKeyspaceName(String keyspaceName) {
80         this.keyspaceName = keyspaceName;
81     }
82
83     @ApiModelProperty(value = "Table Name")
84     public String getTableName() {
85         return tableName;
86     }
87
88     public void setTableName(String tableName) {
89         this.tableName = tableName;
90     }
91
92     @ApiModelProperty(value = "Clustering Order", notes = "")
93     public String getClusteringOrder() {
94         return clusteringOrder;
95     }
96
97     public void setClusteringOrder(String clusteringOrder) {
98         this.clusteringOrder = clusteringOrder;
99     }
100
101     @ApiModelProperty(value = "Primary Key")
102     public String getPrimaryKey() {
103         return primaryKey;
104     }
105
106     public void setPrimaryKey(String primaryKey) {
107         this.primaryKey = primaryKey;
108     }
109
110     public String getClusteringKey() {
111         return clusteringKey;
112     }
113
114     public void setClusteringKey(String clusteringKey) {
115         this.clusteringKey = clusteringKey;
116     }
117
118     public String getFilteringKey() {
119         return filteringKey;
120     }
121
122     public void setFilteringKey(String filteringKey) {
123         this.filteringKey = filteringKey;
124     }
125
126     public String getPartitionKey() {
127         return partitionKey;
128     }
129
130     public void setPartitionKey(String partitionKey) {
131         this.partitionKey = partitionKey;
132     }
133
134
135 }