Merge "Reorder modifiers"
[so.git] / common / src / main / java / org / openecomp / mso / client / defaultproperties / DefaultAAIPropertiesImpl.java
index 354d47a..ce08759 100644 (file)
@@ -40,8 +40,7 @@ public class DefaultAAIPropertiesImpl implements AAIProperties {
        public DefaultAAIPropertiesImpl() {
                File initialFile = new File("src/test/resources/aai.properties");
                Map<Object, Object> temp;
-               try {
-                   InputStream targetStream = new FileInputStream(initialFile);
+               try(InputStream targetStream = new FileInputStream(initialFile)) {
                        Properties properties = new Properties();
                        properties.load(targetStream);
                        temp = properties;
@@ -65,4 +64,15 @@ public class DefaultAAIPropertiesImpl implements AAIProperties {
                return AAIVersion.LATEST;
        }
 
+       @Override
+       public String getAuth() {
+               Object value = props.get("aai.auth");
+               return value == null ? null : value.toString();
+       }
+
+       @Override
+       public String getKey() {
+               Object value = props.get("mso.msoKey");
+               return value == null ? null : value.toString();
+       }
 }