From f0c3f38fc7d23b7d6fcda939aafe57d429b8f41a Mon Sep 17 00:00:00 2001 From: "katy.rotman" Date: Wed, 23 May 2018 15:50:38 +0300 Subject: new node filter implementation Issue-ID: SDC-1363 Change-Id: I0bd8b482e8e55f92ac3bccf8725d64f1b4929a43 Signed-off-by: katy.rotman --- .../tosca/datatypes/model/CapabilityFilter.java | 46 ++++++++++++++++++++++ .../model/CapabilityFilterDefinition.java | 37 ----------------- .../onap/sdc/tosca/datatypes/model/NodeFilter.java | 26 ++++++------ 3 files changed, 58 insertions(+), 51 deletions(-) create mode 100644 common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilter.java delete mode 100644 common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java (limited to 'common') diff --git a/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilter.java b/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilter.java new file mode 100644 index 0000000000..0453325aa2 --- /dev/null +++ b/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilter.java @@ -0,0 +1,46 @@ +/* + * Copyright © 2016-2018 European Support Limited + * + * 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. + */ + +package org.onap.sdc.tosca.datatypes.model; + +import java.util.List; +import java.util.Map; + +/** + * @author KATYR + * @since May 13, 2018 + */ + +public class CapabilityFilter { + + List>> properties; + + public List>> getProperties() { + return properties; + } + + public void setProperties(List>> properties) { + this.properties = properties; + } + + @Override + public String toString() { + final StringBuilder sb = new StringBuilder("CapabilityFilter{"); + sb.append("properties=").append(properties); + sb.append('}'); + return sb.toString(); + } +} diff --git a/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java b/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java deleted file mode 100644 index 83f9d2576b..0000000000 --- a/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/CapabilityFilterDefinition.java +++ /dev/null @@ -1,37 +0,0 @@ -/*- - * ============LICENSE_START======================================================= - * SDC - * ================================================================================ - * 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.sdc.tosca.datatypes.model; - -import java.util.List; - - - -public class CapabilityFilterDefinition { - List properties; - - public List getProperties() { - return properties; - } - - public void setProperties(List properties) { - this.properties = properties; - } -} diff --git a/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/NodeFilter.java b/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/NodeFilter.java index 692d7e47ee..d1d07b56e6 100644 --- a/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/NodeFilter.java +++ b/common/onap-tosca-datatype/src/main/java/org/onap/sdc/tosca/datatypes/model/NodeFilter.java @@ -7,9 +7,9 @@ * 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. @@ -24,26 +24,24 @@ import java.util.List; import java.util.Map; - public class NodeFilter { - Map> properties; - Map capabilities; - - public Map> getProperties() { + List>> properties; + List> capabilities; - return properties; + public List> getCapabilities() { + return capabilities; } - public void setProperties(Map> properties) { - this.properties = properties; + public void setCapabilities(List> capabilities) { + this.capabilities = capabilities; } - public Map getCapabilities() { - return capabilities; + public List>> getProperties() { + return properties; } - public void setCapabilities(Map capabilities) { - this.capabilities = capabilities; + public void setProperties(List>> properties) { + this.properties = properties; } } -- cgit 1.2.3-korg