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.conductor.conditionals;
25 import java.io.Serializable;
28 import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
30 import io.swagger.annotations.ApiModel;
32 @ApiModel(value = "JsonConditional", description = "Json model for insert or update into table based on some conditions")
33 @JsonIgnoreProperties(ignoreUnknown = true)
34 public class JsonConditional implements Serializable {
36 private String primaryKey;
37 private String primaryKeyValue;
38 private String casscadeColumnName;
39 private Map<String,Object> tableValues;
40 private Map<String,Object> casscadeColumnData;
41 private Map<String,Map<String,String>> conditions;
43 public Map<String, Object> getTableValues() {
46 public void setTableValues(Map<String, Object> tableValues) {
47 this.tableValues = tableValues;
50 public String getPrimaryKey() {
53 public String getPrimaryKeyValue() {
54 return primaryKeyValue;
56 public String getCasscadeColumnName() {
57 return casscadeColumnName;
60 public Map<String, Object> getCasscadeColumnData() {
61 return casscadeColumnData;
66 public void setPrimaryKey(String primaryKey) {
67 this.primaryKey = primaryKey;
69 public void setPrimaryKeyValue(String primaryKeyValue) {
70 this.primaryKeyValue = primaryKeyValue;
72 public Map<String, Map<String, String>> getConditions() {
75 public void setConditions(Map<String, Map<String, String>> conditions) {
76 this.conditions = conditions;
78 public void setCasscadeColumnName(String casscadeColumnName) {
79 this.casscadeColumnName = casscadeColumnName;
82 public void setCasscadeColumnData(Map<String, Object> casscadeColumnData) {
83 this.casscadeColumnData = casscadeColumnData;