summaryrefslogtreecommitdiffstats
path: root/models-tosca/src/main/java
diff options
context:
space:
mode:
authorRossC <ross.carter@est.tech>2020-06-09 14:35:41 +0100
committerRossC <ross.carter@est.tech>2020-06-09 16:19:32 +0100
commit5dc52f7d5b3dadc422e58823b1086084a25788a3 (patch)
tree802f91ead1c8dc2e9d2002ab28d27927e5d7220a /models-tosca/src/main/java
parent53bc2418c365246d457a09d2cded0d9bde9c212b (diff)
Changing toString on ToscaPolicyXXXIdentifiers
Issue-ID: POLICY-2078 Change-Id: I0e8aae118a52aaef7e372293396802b85782a22c Signed-off-by: RossC <ross.carter@est.tech>
Diffstat (limited to 'models-tosca/src/main/java')
-rw-r--r--models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifier.java6
-rw-r--r--models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifierOptVersion.java6
-rw-r--r--models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyTypeIdentifier.java6
3 files changed, 18 insertions, 0 deletions
diff --git a/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifier.java b/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifier.java
index f98a238ff..ba1042851 100644
--- a/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifier.java
+++ b/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifier.java
@@ -3,6 +3,7 @@
* ONAP Policy Models
* ================================================================================
* Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2020 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -83,4 +84,9 @@ public class ToscaPolicyIdentifier implements Comparable<ToscaPolicyIdentifier>
return ObjectUtils.compare(getVersion(), other.getVersion());
}
+
+ @Override
+ public String toString() {
+ return this.name + " " + this.version;
+ }
}
diff --git a/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifierOptVersion.java b/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifierOptVersion.java
index ca3684a24..43e7114be 100644
--- a/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifierOptVersion.java
+++ b/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyIdentifierOptVersion.java
@@ -3,6 +3,7 @@
* ONAP Policy Models
* ================================================================================
* Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2020 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -73,4 +74,9 @@ public class ToscaPolicyIdentifierOptVersion implements Comparable<ToscaPolicyId
return ObjectUtils.compare(getVersion(), other.getVersion());
}
+
+ @Override
+ public String toString() {
+ return this.name + " " + this.version;
+ }
}
diff --git a/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyTypeIdentifier.java b/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyTypeIdentifier.java
index 4cd1764de..32dd7cbd7 100644
--- a/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyTypeIdentifier.java
+++ b/models-tosca/src/main/java/org/onap/policy/models/tosca/authorative/concepts/ToscaPolicyTypeIdentifier.java
@@ -3,6 +3,7 @@
* ONAP Policy Models
* ================================================================================
* Copyright (C) 2019 AT&T Intellectual Property. All rights reserved.
+ * Modifications Copyright (C) 2020 Nordix Foundation.
* ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -83,4 +84,9 @@ public class ToscaPolicyTypeIdentifier implements Comparable<ToscaPolicyTypeIden
return ObjectUtils.compare(getVersion(), other.getVersion());
}
+
+ @Override
+ public String toString() {
+ return this.name + " " + this.version;
+ }
}