2 * ============LICENSE_START==========================================
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
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.
19 * ============LICENSE_END=============================================
20 * ====================================================================
23 package org.onap.music.datastore.jsonobjects;
27 import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
29 import io.swagger.annotations.ApiModel;
30 import io.swagger.annotations.ApiModelProperty;
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;
38 private Map<String, String> fields;
39 private Map<String, Object> properties;
40 private String primaryKey;
41 private String sortingKey;
42 private String clusteringOrder;
43 private Map<String, String> consistencyInfo;
45 @ApiModelProperty(value = "Consistency level", allowableValues = "eventual,critical,atomic")
46 public Map<String, String> getConsistencyInfo() {
47 return consistencyInfo;
50 public void setConsistencyInfo(Map<String, String> consistencyInfo) {
51 this.consistencyInfo = consistencyInfo;
54 @ApiModelProperty(value = "Properties")
55 public Map<String, Object> getProperties() {
59 public void setProperties(Map<String, Object> properties) {
60 this.properties = properties;
63 @ApiModelProperty(value = "Fields")
64 public Map<String, String> getFields() {
68 public void setFields(Map<String, String> fields) {
72 @ApiModelProperty(value = "KeySpace Name")
73 public String getKeyspaceName() {
77 public void setKeyspaceName(String keyspaceName) {
78 this.keyspaceName = keyspaceName;
81 @ApiModelProperty(value = "Table Name")
82 public String getTableName() {
86 public void setTableName(String tableName) {
87 this.tableName = tableName;
90 @ApiModelProperty(value = "Sorting Key")
91 public String getSortingKey() {
95 public void setSortingKey(String sortingKey) {
96 this.sortingKey = sortingKey;
99 @ApiModelProperty(value = "Clustering Order", notes = "")
100 public String getClusteringOrder() {
101 return clusteringOrder;
104 public void setClusteringOrder(String clusteringOrder) {
105 this.clusteringOrder = clusteringOrder;
108 @ApiModelProperty(value = "Primary Key")
109 public String getPrimaryKey() {
113 public void setPrimaryKey(String primaryKey) {
114 this.primaryKey = primaryKey;