diff options
author | Rich Tabedzki <richard.tabedzki@att.com> | 2019-03-06 13:47:05 -0500 |
---|---|---|
committer | Rich Tabedzki <richard.tabedzki@att.com> | 2019-03-06 14:47:16 -0500 |
commit | 62f2bacc7680182412968f3cbb7ab7acd2f2eef1 (patch) | |
tree | 169faa8a35e65b70ec456d0c961517b2ce19c381 /aai-service/provider/src/main/java | |
parent | e73462e38b5a282e7308a8d92a155e47f79d1b0e (diff) |
Deprecated named-query from AAIService
Changes made:
* Removed named-query feature from AAIService codebase
* Removed any additional unused classes
* cleaned up aaiclient.properties
* Removed related junit tests
Change-Id: Ic9fffbff0eaa85a80f1aa0781c5e675e4bc44602
Issue-ID: CCSDK-1108
Signed-off-by: Rich Tabedzki <richard.tabedzki@att.com>
Diffstat (limited to 'aai-service/provider/src/main/java')
8 files changed, 1 insertions, 606 deletions
diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIDeclarations.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIDeclarations.java index 3fa95495..11f4f653 100755 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIDeclarations.java +++ b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIDeclarations.java @@ -55,11 +55,6 @@ import javax.xml.bind.annotation.XmlType; import org.apache.commons.lang.StringUtils; import org.onap.ccsdk.sli.adaptors.aai.data.AAIDatum; import org.onap.ccsdk.sli.adaptors.aai.query.FormattedQueryResultList; -import org.onap.ccsdk.sli.adaptors.aai.query.InstanceFilter; -import org.onap.ccsdk.sli.adaptors.aai.query.InstanceFilters; -import org.onap.ccsdk.sli.adaptors.aai.query.NamedQuery; -import org.onap.ccsdk.sli.adaptors.aai.query.NamedQueryData; -import org.onap.ccsdk.sli.adaptors.aai.query.QueryParameters; import org.onap.ccsdk.sli.adaptors.aai.query.Result; import org.onap.ccsdk.sli.core.sli.SvcLogicContext; import org.onap.ccsdk.sli.core.sli.SvcLogicException; @@ -136,9 +131,6 @@ public abstract class AAIDeclarations implements AAIClient { //Service public static final String SERVICE_PATH = "org.onap.ccsdk.sli.adaptors.aai.path.service"; - // P-Interfaces - public static final String P_INTERFACE_PATH = "org.onap.ccsdk.sli.adaptors.aai.path.pserver.pinterface"; - // site-pair-sets public static final String SITE_PAIR_SET_PATH = "org.onap.ccsdk.sli.adaptors.aai.path.site.pair.set"; @@ -151,7 +143,7 @@ public abstract class AAIDeclarations implements AAIClient { protected abstract Logger getLogger(); public abstract AAIExecutorInterface getExecutor(); - + private static final String RELATIONSHIP_DATA= "Retrofitting relationship data: "; @@ -797,8 +789,6 @@ public abstract class AAIDeclarations implements AAIClient { if(!tmpParams.isEmpty()) { params.putAll(tmpParams); } - if("named-query".equals(resource)) - request.setRequestObject(extractNamedQueryDataFromQueryPrefix(nameValues, params)); } String rv = getExecutor().get(request); @@ -860,14 +850,6 @@ public abstract class AAIDeclarations implements AAIClient { } } - if("named-query".equals(resource)) { - InventoryResponseItems rd = InventoryResponseItems.class.cast(response); - List<InventoryResponseItem> iRIlist = rd.getInventoryResponseItem(); - if(iRIlist == null || iRIlist.isEmpty()) { - return QueryStatus.NOT_FOUND; - } - } - if("nodes-query".equals(resource)) { SearchResults rd = SearchResults.class.cast(response); List<ResultData> rdList = rd.getResultData(); @@ -2016,114 +1998,6 @@ public abstract class AAIDeclarations implements AAIClient { return prefixMap; } - /** - */ - protected NamedQueryData extractNamedQueryDataFromQueryPrefix(HashMap<String, String> nameValues, Map<String, String> parms) { - if(parms.isEmpty()) { - return null; - } - - NamedQueryData data = new NamedQueryData(); - - // query parameters - if(data.getQueryParameters() == null) { - data.setQueryParameters(new QueryParameters()); - } - String namedQueryUuid = nameValues.get("named-query-uuid".replaceAll("-", "_")); - if(namedQueryUuid == null) { - namedQueryUuid = parms.get("query-parameters.named-query.named-query-uuid"); - } - NamedQuery namedQuery = new NamedQuery(); - namedQuery.setNamedQueryUuid(namedQueryUuid); - data.getQueryParameters().setNamedQuery(namedQuery); - - // instance filters - if(data.getInstanceFilters() == null) { - data.setInstanceFilters(new InstanceFilters()); - } - - - String quantity = parms.get("instance-filters.instance-filter_length"); - if(quantity != null && StringUtils.isNumeric(quantity)) { - int max = Integer.parseInt(quantity); - for(int i = 0; i < max; i++) { - String keyPattern = String.format("instance-filters.instance-filter[%d].", i); - Set<String> keys = parms.keySet(); - for(String key: keys) { - if(key.startsWith(keyPattern)){ - String value = parms.get(key); - String remainder = key.substring(keyPattern.length()); - String[] split = remainder.split("\\."); - getLogger().debug(String.format("%s", remainder)); - if("logical-link".equals(split[0])) { - InstanceFilter insf = null; - if(data.getInstanceFilters().getInstanceFilter().isEmpty()) { - insf = new InstanceFilter(); - data.getInstanceFilters().getInstanceFilter().add(insf); - } else { - insf = data.getInstanceFilters().getInstanceFilter().get(0); - } - LogicalLink logicalLink = insf.getLogicalLink(); - if(logicalLink == null) { - logicalLink = new LogicalLink(); - insf.setLogicalLink(logicalLink); - } - - switch(split[1]) { - case "link-name": - logicalLink.setLinkName(value); - break; - case "link-type": - logicalLink.setLinkType(value); - break; - case "operational-state": - logicalLink.setOperationalStatus(value); - break; - } - - } else if("pnf".equals(split[0])) { - Pnf pnf = new Pnf(); - pnf.setPnfName(value); - - InstanceFilter insf = new InstanceFilter(); - insf.setPnf(pnf); - data.getInstanceFilters().getInstanceFilter().add(insf); - - } else if("service-instance".equals(split[0])) { - ServiceInstance serviceInstance = new ServiceInstance(); - serviceInstance.setServiceInstanceId(value); - - InstanceFilter insf = new InstanceFilter(); - insf.setServiceInstance(serviceInstance); - data.getInstanceFilters().getInstanceFilter().add(insf); - - } else if("l3-network".equals(split[0])) { - L3Network l3Network = new L3Network(); - if("network-role".equals(split[1])) { - l3Network.setNetworkRole(value); - } - - InstanceFilter insf = new InstanceFilter(); - insf.setL3Network(l3Network); - data.getInstanceFilters().getInstanceFilter().add(insf); - } else if("generic-vnf".equals(split[0])) { - GenericVnf vnf = new GenericVnf(); - if("vnf-id".equals(split[1])) { - vnf.setVnfId(value); - } - - InstanceFilter insf = new InstanceFilter(); - insf.setGenericVnf(vnf); - data.getInstanceFilters().getInstanceFilter().add(insf); - } - } - } - } - } - - return data; - } - public abstract <T> T getResource(String key, Class<T> type) throws AAIServiceException ; protected abstract boolean deleteList(URL url, String caller) throws AAIServiceException; } diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIRequest.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIRequest.java index 04312fd7..0edd09df 100755 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIRequest.java +++ b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIRequest.java @@ -117,8 +117,6 @@ public abstract class AAIRequest { switch(resoource){ case "generic-query": return new GenericQueryRequest(); - case "named-query": - return new NamedQueryRequest(); case "nodes-query": return new NodesQueryRequest(); case "custom-query": diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java index 2411d292..d315f64b 100755 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java +++ b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIService.java @@ -219,8 +219,6 @@ public class AAIService extends AAIDeclarations implements AAIClient, SvcLogicRe svc_inst_query_path = props.getProperty(SVC_INST_QRY_PATH); props.getProperty(PARAM_SERVICE_TYPE, "service-type"); - props.getProperty(P_INTERFACE_PATH); - props.getProperty(VNF_IMAGE_QUERY_PATH); ubb_notify_path = props.getProperty(UBB_NOTIFY_PATH); @@ -1358,7 +1356,6 @@ public class AAIService extends AAIDeclarations implements AAIClient, SvcLogicRe case "custom-query": case "formatted-query": case "generic-query": - case "named-query": case "nodes-query": case "linterface": case "l2-bridge-sbg": @@ -1387,7 +1384,6 @@ public class AAIService extends AAIDeclarations implements AAIClient, SvcLogicRe case "custom-query": case "formatted-query": case "generic-query": - case "named-query": case "nodes-query": case "linterface": case "l2-bridge-sbg": @@ -1416,7 +1412,6 @@ public class AAIService extends AAIDeclarations implements AAIClient, SvcLogicRe case "custom-query": case "formatted-query": case "generic-query": - case "named-query": case "nodes-query": case "linterface": case "l2-bridge-sbg": @@ -1445,7 +1440,6 @@ public class AAIService extends AAIDeclarations implements AAIClient, SvcLogicRe case "custom-query": case "formatted-query": case "generic-query": - case "named-query": case "nodes-query": case "linterface": case "l2-bridge-sbg": diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIServiceUtils.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIServiceUtils.java index 3bd6ac49..e773da52 100755 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIServiceUtils.java +++ b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/AAIServiceUtils.java @@ -330,7 +330,6 @@ public class AAIServiceUtils { case "custom-query": case "formatted-query": case "generic-query": - case "named-query": case "nodes-query": case "linterface": case "l2-bridge-sbg": @@ -365,7 +364,6 @@ public class AAIServiceUtils { case "custom-query": case "formatted-query": case "generic-query": - case "named-query": case "nodes-query": case "linterface": case "l2-bridge-sbg": diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/NamedQueryRequest.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/NamedQueryRequest.java deleted file mode 100755 index d6df6286..00000000 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/NamedQueryRequest.java +++ /dev/null @@ -1,215 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * openECOMP : SDN-C - * ================================================================================ - * Copyright (C) 2017 AT&T Intellectual Property. All rights - * reserved. - * ================================================================================ - * Modifications Copyright (C) 2018 IBM. - * ================================================================================ - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * ============LICENSE_END========================================================= - */ -/** - * @author Rich Tabedzki - * - */ -package org.onap.ccsdk.sli.adaptors.aai; - -import java.io.UnsupportedEncodingException; -import java.net.MalformedURLException; -import java.net.URL; -import java.util.ArrayList; -import java.util.Iterator; -import java.util.List; -import java.util.Properties; - -import org.onap.ccsdk.sli.adaptors.aai.data.AAIDatum; -import org.onap.aai.inventory.v14.InventoryResponseItems; - -import com.fasterxml.jackson.annotation.JsonInclude.Include; -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.AnnotationIntrospector; -import com.fasterxml.jackson.databind.DeserializationFeature; -import com.fasterxml.jackson.databind.JsonNode; -import com.fasterxml.jackson.databind.ObjectMapper; -import com.fasterxml.jackson.databind.introspect.JacksonAnnotationIntrospector; -import com.fasterxml.jackson.databind.node.ObjectNode; -import com.fasterxml.jackson.databind.type.TypeFactory; -import com.fasterxml.jackson.module.jaxb.JaxbAnnotationIntrospector; - -public class NamedQueryRequest extends AAIRequest { - - public static final String NAMED_SEARCH_PATH = "org.onap.ccsdk.sli.adaptors.aai.query.named"; - - private final String named_search_path; - - public static final String NAMED_QUERY_UUID = "named-query-uuid"; - public static final String PREFIX = "prefix"; - - - public NamedQueryRequest() { - named_search_path = configProperties.getProperty(NAMED_SEARCH_PATH); - } - - @Override - public URL getRequestUrl(String method, String resourceVersion) throws UnsupportedEncodingException, MalformedURLException { - - String request_url = targetUri+named_search_path; - - request_url = processPathData(request_url, requestProperties); - - if(resourceVersion != null) { - request_url = request_url +"?resource-version="+resourceVersion; - } - URL http_req_url = new URL(request_url); - - aaiService.LOGwriteFirstTrace(method, http_req_url.toString()); - - return http_req_url; - } - - @Override - public URL getRequestQueryUrl(String method) throws UnsupportedEncodingException, MalformedURLException { - return getRequestUrl(method, null); - } - - - @Override - public String toJSONString() { - ObjectMapper mapper = AAIService.getObjectMapper(); - mapper.setSerializationInclusion(Include.NON_NULL); - mapper.setSerializationInclusion(Include.NON_EMPTY); - mapper.setSerializationInclusion(Include.NON_DEFAULT); - - AnnotationIntrospector introspector = new JaxbAnnotationIntrospector(TypeFactory.defaultInstance()); - AnnotationIntrospector secondary = new JacksonAnnotationIntrospector(); - mapper.setAnnotationIntrospector(AnnotationIntrospector.pair(introspector, secondary)); - mapper.disable(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES); - - AAIDatum tenant = (AAIDatum)requestDatum; - String json_text = null; - try { - ObjectNode node = mapper.valueToTree(tenant); - Iterator<JsonNode> it = node.elements(); - while(it.hasNext()){ - JsonNode jn = it.next(); - JsonNode child = jn.get("instance-filter"); - if(child != null) { - child = child.get(0); - if(child.has("l3-network")) { - JsonNode innerChild = child.get("l3-network"); - if(innerChild != null) { - if(innerChild instanceof ObjectNode) { - ObjectNode on = ObjectNode.class.cast(innerChild); - List<String> namesToDelete = new ArrayList<>(); - Iterator<String> names = on.fieldNames(); - while(names.hasNext()) { - String name = names.next(); - if(name != null && name.startsWith("is-")) { - namesToDelete.add(name); - } - } - for(String nameToDelete : namesToDelete) { - on.remove(nameToDelete); - } - } - } - } else if(child.has("pnf")) { - JsonNode innerChild = child.get("pnf"); - if(innerChild != null) { - if(innerChild instanceof ObjectNode) { - ObjectNode on = ObjectNode.class.cast(innerChild); - List<String> namesToDelete = new ArrayList<>(); - Iterator<String> names = on.fieldNames(); - while(names.hasNext()) { - String name = names.next(); - if(name != null && name.startsWith("in-maint")) { - namesToDelete.add(name); - } - } - for(String nameToDelete : namesToDelete) { - on.remove(nameToDelete); - } - } - } - } else if(child.has("generic-vnf")) { - JsonNode innerChild = child.get("generic-vnf"); - if(innerChild != null) { - if(innerChild instanceof ObjectNode) { - ObjectNode on = ObjectNode.class.cast(innerChild); - List<String> namesToDelete = new ArrayList<>(); - Iterator<String> names = on.fieldNames(); - while(names.hasNext()) { - String name = names.next(); - if(name != null && name.startsWith("is-")) { - namesToDelete.add(name); - } else if(name != null && name.startsWith("in-maint")) { - namesToDelete.add(name); - } - } - for(String nameToDelete : namesToDelete) { - on.remove(nameToDelete); - } - } - } - } - } - } - json_text = node.toString(); - if(json_text == null) - json_text = mapper.writeValueAsString(tenant); - } catch (JsonProcessingException exc) { - handleException(this, exc); - return null; - } - return json_text; - } - - - @Override - public String[] getArgsList() { - String[] args = {NAMED_QUERY_UUID, PREFIX}; - return args; - } - - - @Override - public Class<? extends AAIDatum> getModelClass() { - return InventoryResponseItems.class; - } - - - public static String processPathData(String request_url, Properties requestProperties) throws UnsupportedEncodingException { - - - String encoded_vnf ; - String key = NAMED_QUERY_UUID; - - if(requestProperties.containsKey(key)) { - encoded_vnf = encodeQuery(requestProperties.getProperty(key)); - request_url = request_url.replace("{named-query-uuid}", encoded_vnf) ; - aaiService.LOGwriteDateTrace(NAMED_QUERY_UUID, requestProperties.getProperty(key)); - } - - key = PREFIX; - - if(requestProperties.containsKey(key)) { - encoded_vnf = encodeQuery(requestProperties.getProperty(key)); - request_url = request_url.replace("{prefix}", encoded_vnf) ; - aaiService.LOGwriteDateTrace(PREFIX, requestProperties.getProperty(key)); - } - - return request_url; - } -} diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/NamedQuery.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/NamedQuery.java deleted file mode 100644 index 170fa78a..00000000 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/NamedQuery.java +++ /dev/null @@ -1,76 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * openECOMP : SDN-C - * ================================================================================ - * Copyright (C) 2017 AT&T Intellectual Property. All rights - * reserved. - * ================================================================================ - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * ============LICENSE_END========================================================= - */ - -package org.onap.ccsdk.sli.adaptors.aai.query; - -import java.util.HashMap; -import java.util.Map; -import javax.annotation.Generated; -import com.fasterxml.jackson.annotation.JsonAnyGetter; -import com.fasterxml.jackson.annotation.JsonAnySetter; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonPropertyOrder; - -@JsonInclude(JsonInclude.Include.NON_NULL) -@Generated("org.jsonschema2pojo") -@JsonPropertyOrder({ - "named-query-uuid" -}) -public class NamedQuery { - - @JsonProperty("named-query-uuid") - private String namedQueryUuid; - @JsonIgnore - private Map<String, Object> additionalProperties = new HashMap<String, Object>(); - - /** - * - * @return - * The namedQueryUuid - */ - @JsonProperty("named-query-uuid") - public String getNamedQueryUuid() { - return namedQueryUuid; - } - - /** - * - * @param namedQueryUuid - * The named-query-uuid - */ - @JsonProperty("named-query-uuid") - public void setNamedQueryUuid(String namedQueryUuid) { - this.namedQueryUuid = namedQueryUuid; - } - - @JsonAnyGetter - public Map<String, Object> getAdditionalProperties() { - return this.additionalProperties; - } - - @JsonAnySetter - public void setAdditionalProperty(String name, Object value) { - this.additionalProperties.put(name, value); - } - -} diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/NamedQueryData.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/NamedQueryData.java deleted file mode 100644 index f7170246..00000000 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/NamedQueryData.java +++ /dev/null @@ -1,102 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * openECOMP : SDN-C - * ================================================================================ - * Copyright (C) 2017 AT&T Intellectual Property. All rights - * reserved. - * ================================================================================ - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * ============LICENSE_END========================================================= - */ - -package org.onap.ccsdk.sli.adaptors.aai.query; - -import java.util.HashMap; -import java.util.Map; -import javax.annotation.Generated; - -import org.onap.ccsdk.sli.adaptors.aai.data.AAIDatum; - -import com.fasterxml.jackson.annotation.JsonAnyGetter; -import com.fasterxml.jackson.annotation.JsonAnySetter; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonPropertyOrder; - -@JsonInclude(JsonInclude.Include.NON_NULL) -@Generated("org.jsonschema2pojo") -@JsonPropertyOrder({ - "query-parameters", - "instance-filters" -}) -public class NamedQueryData implements AAIDatum { - - @JsonProperty("query-parameters") - private QueryParameters queryParameters; - @JsonProperty("instance-filters") - private InstanceFilters instanceFilters; - @JsonIgnore - private Map<String, Object> additionalProperties = new HashMap<String, Object>(); - - /** - * - * @return - * The queryParameters - */ - @JsonProperty("query-parameters") - public QueryParameters getQueryParameters() { - return queryParameters; - } - - /** - * - * @param queryParameters - * The query-parameters - */ - @JsonProperty("query-parameters") - public void setQueryParameters(QueryParameters queryParameters) { - this.queryParameters = queryParameters; - } - - /** - * - * @return - * The instanceFilters - */ - @JsonProperty("instance-filters") - public InstanceFilters getInstanceFilters() { - return instanceFilters; - } - - /** - * - * @param instanceFilters - * The instance-filters - */ - @JsonProperty("instance-filters") - public void setInstanceFilters(InstanceFilters instanceFilters) { - this.instanceFilters = instanceFilters; - } - - @JsonAnyGetter - public Map<String, Object> getAdditionalProperties() { - return this.additionalProperties; - } - - @JsonAnySetter - public void setAdditionalProperty(String name, Object value) { - this.additionalProperties.put(name, value); - } - -} diff --git a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/QueryParameters.java b/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/QueryParameters.java deleted file mode 100644 index ba37900a..00000000 --- a/aai-service/provider/src/main/java/org/onap/ccsdk/sli/adaptors/aai/query/QueryParameters.java +++ /dev/null @@ -1,76 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * openECOMP : SDN-C - * ================================================================================ - * Copyright (C) 2017 AT&T Intellectual Property. All rights - * reserved. - * ================================================================================ - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - * ============LICENSE_END========================================================= - */ - -package org.onap.ccsdk.sli.adaptors.aai.query; - -import java.util.HashMap; -import java.util.Map; -import javax.annotation.Generated; -import com.fasterxml.jackson.annotation.JsonAnyGetter; -import com.fasterxml.jackson.annotation.JsonAnySetter; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonInclude; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonPropertyOrder; - -@JsonInclude(JsonInclude.Include.NON_NULL) -@Generated("org.jsonschema2pojo") -@JsonPropertyOrder({ - "named-query" -}) -public class QueryParameters { - - @JsonProperty("named-query") - private NamedQuery namedQuery; - @JsonIgnore - private Map<String, Object> additionalProperties = new HashMap<String, Object>(); - - /** - * - * @return - * The namedQuery - */ - @JsonProperty("named-query") - public NamedQuery getNamedQuery() { - return namedQuery; - } - - /** - * - * @param namedQuery - * The named-query - */ - @JsonProperty("named-query") - public void setNamedQuery(NamedQuery namedQuery) { - this.namedQuery = namedQuery; - } - - @JsonAnyGetter - public Map<String, Object> getAdditionalProperties() { - return this.additionalProperties; - } - - @JsonAnySetter - public void setAdditionalProperty(String name, Object value) { - this.additionalProperties.put(name, value); - } - -} |