Improve the performance of resoures microservice
[aai/aai-common.git] / aai-core / src / main / java / org / onap / aai / introspection / Loader.java
index ea323c5..cae4cbb 100644 (file)
@@ -22,51 +22,52 @@ package org.onap.aai.introspection;
 import org.onap.aai.introspection.exceptions.AAIUnknownObjectException;
 import org.onap.aai.introspection.exceptions.AAIUnmarshallingException;
 import org.onap.aai.restcore.MediaType;
+import org.onap.aai.setup.SchemaVersion;
 
 import java.util.Map;
+import java.util.Set;
 
 public abstract class Loader {
 
-       private final Version version;
+       private final SchemaVersion version;
        private final ModelType modelType;
-       
+
        /**
         * Instantiates a new loader.
         *
         * @param version the version
         * @param modelType the model type
-        * @param llBuilder the ll builder
         */
-       public Loader (Version version, ModelType modelType) {
+       public Loader (SchemaVersion version, ModelType modelType) {
                this.version = version;
                this.modelType = modelType;
        }
-       
+
        /**
         * Process.
         *
         * @param version the version
         */
-       protected abstract void process(Version version);
-       
+       protected abstract void process(SchemaVersion version);
+
        /**
         * Object from name.
         *
         * @param name the name
         * @return the object
-        * @throws AAIUnknownObjectException 
+        * @throws AAIUnknownObjectException
         */
        public abstract Object objectFromName(String name) throws AAIUnknownObjectException;
-       
+
        /**
         * Introspector from name.
         *
         * @param name the name
         * @return the introspector
-        * @throws AAIUnknownObjectException 
+        * @throws AAIUnknownObjectException
         */
        public abstract Introspector introspectorFromName(String name) throws AAIUnknownObjectException;
-       
+
        /**
         * Unmarshal.
         *
@@ -76,7 +77,7 @@ public abstract class Loader {
         * @return the introspector
         */
        public abstract Introspector unmarshal(String type, String json, MediaType mediaType) throws AAIUnmarshallingException;
-       
+
        /**
         * Unmarshal.
         *
@@ -88,7 +89,7 @@ public abstract class Loader {
                return unmarshal(type, json, MediaType.APPLICATION_JSON_TYPE);
        }
 
-       
+
        /**
         * Gets the model type.
         *
@@ -97,15 +98,17 @@ public abstract class Loader {
        public ModelType getModelType() {
                return this.modelType;
        }
-       
+
        /**
         * Gets the version.
         *
         * @return the version
         */
-       public Version getVersion() {
+       public SchemaVersion getVersion() {
                return this.version;
        }
-       
+
        public abstract Map<String, Introspector> getAllObjects();
+
+    public abstract Set<String> getNamedPropNodes();
 }