Restructure for authorative models
[policy/models.git] / models-tosca / src / main / java / org / onap / policy / models / tosca / simple / concepts / JpaToscaModel.java
@@ -46,7 +46,7 @@ import org.onap.policy.models.base.PfValidationResult;
  * class that allows a model with many service templates to be constructed that contains a well
  * formed overall TOSCA model.
  *
- * <p>Validation runs {@link ToscaModel} validation on the model and all its sub concepts.
+ * <p>Validation runs {@link JpaToscaModel} validation on the model and all its sub concepts.
  */
 
 @Entity
@@ -54,37 +54,37 @@ import org.onap.policy.models.base.PfValidationResult;
 @Inheritance(strategy = InheritanceType.TABLE_PER_CLASS)
 @Data
 @EqualsAndHashCode(callSuper = true)
-public class ToscaModel extends PfModel {
+public class JpaToscaModel extends PfModel {
     private static final long serialVersionUID = 8800599637708309945L;
 
     @OneToOne(cascade = CascadeType.ALL)
-    private ToscaServiceTemplates serviceTemplates;
+    private JpaToscaServiceTemplates serviceTemplates;
 
     /**
-     * The Default Constructor creates a {@link ToscaModel} object with a null concept key and
+     * The Default Constructor creates a {@link JpaToscaModel} object with a null concept key and
      * creates an empty TOSCA model.
      */
-    public ToscaModel() {
+    public JpaToscaModel() {
         this(new PfConceptKey());
     }
 
     /**
-     * The Key Constructor creates a {@link ToscaModel} object with the given concept key and
+     * The Key Constructor creates a {@link JpaToscaModel} object with the given concept key and
      * creates an empty TOSCA model.
      *
      * @param key the TOSCA model key
      */
-    public ToscaModel(final PfConceptKey key) {
-        this(key, new ToscaServiceTemplates(new PfConceptKey()));
+    public JpaToscaModel(final PfConceptKey key) {
+        this(key, new JpaToscaServiceTemplates(new PfConceptKey()));
     }
 
     /**
-     * Constructor that initiates a {@link ToscaModel} with all its fields.
+     * Constructor that initiates a {@link JpaToscaModel} with all its fields.
      *
      * @param key the TOSCA model key
      * @param serviceTemplates the service templates in the event model
      */
-    public ToscaModel(@NonNull final PfConceptKey key, @NonNull final ToscaServiceTemplates serviceTemplates) {
+    public JpaToscaModel(@NonNull final PfConceptKey key, @NonNull final JpaToscaServiceTemplates serviceTemplates) {
         super(key);
         this.serviceTemplates = serviceTemplates;
     }
@@ -94,7 +94,7 @@ public class ToscaModel extends PfModel {
      *
      * @param copyConcept the concept to copy from
      */
-    public ToscaModel(@NonNull final ToscaModel copyConcept) {
+    public JpaToscaModel(@NonNull final JpaToscaModel copyConcept) {
         super(copyConcept);
     }
 
@@ -139,7 +139,7 @@ public class ToscaModel extends PfModel {
             return this.hashCode() - otherConcept.hashCode();
         }
 
-        final ToscaModel other = (ToscaModel) otherConcept;
+        final JpaToscaModel other = (JpaToscaModel) otherConcept;
         if (!super.equals(other)) {
             return super.compareTo(other);
         }
@@ -149,11 +149,11 @@ public class ToscaModel extends PfModel {
 
     @Override
     public PfConcept copyTo(@NonNull final PfConcept targetObject) {
-        Assertions.instanceOf(targetObject, ToscaModel.class);
+        Assertions.instanceOf(targetObject, JpaToscaModel.class);
 
-        final ToscaModel copy = ((ToscaModel) targetObject);
+        final JpaToscaModel copy = ((JpaToscaModel) targetObject);
         super.copyTo(targetObject);
-        copy.setServiceTemplates(new ToscaServiceTemplates(serviceTemplates));
+        copy.setServiceTemplates(new JpaToscaServiceTemplates(serviceTemplates));
 
         return copy;
     }