X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=src%2Fmain%2Fjava%2Forg%2Fonap%2Fschema%2Futil%2FSchemaIngestPropertyReader.java;h=ca5fa6b79aa2ccd075710b441b3ebf7b9caa8455;hb=18f7af386802e750ad983ba2cdf4d9b84b4ed5ed;hp=71ea47eb3d44fb4d17c34ad0b31822f75d984931;hpb=18703cdc19842806969d30f19f8171469c79a0fe;p=aai%2Fgizmo.git diff --git a/src/main/java/org/onap/schema/util/SchemaIngestPropertyReader.java b/src/main/java/org/onap/schema/util/SchemaIngestPropertyReader.java index 71ea47e..ca5fa6b 100644 --- a/src/main/java/org/onap/schema/util/SchemaIngestPropertyReader.java +++ b/src/main/java/org/onap/schema/util/SchemaIngestPropertyReader.java @@ -46,11 +46,37 @@ public class SchemaIngestPropertyReader { * Gets the location of the OXM * * @return - * @throws SpikeException - * @throws IOException + * @throws CrudException */ public String getNodeDir() throws CrudException { + return getProps ().getProperty("nodeDir"); + } + + /** + * Gets the location of the Edge Rules + * + * @return + * @throws CrudException + */ + public String getEdgeDir() throws CrudException { + + return getProps ().getProperty("edgeDir"); + } + + /** + * Gets the location of the Edge Properties + * + * @return + * @throws CrudException + */ + public String getEdgePropsDir() throws CrudException { + + return getProps ().getProperty("edgePropsDir"); + } + + private Properties getProps() throws CrudException { + Properties prop = new Properties(); try { prop = loadFromFile(SCHEMA_INGEST_PROPERTIES_LOCATION); @@ -66,7 +92,7 @@ public class SchemaIngestPropertyReader { logger.error(CrudServiceMsgs.SCHEMA_INGEST_LOAD_ERROR, e.getMessage()); throw new CrudException("Failed to load schemaIngest.properties", e); } - return prop.getProperty("nodeDir"); + return prop; } private Properties loadFromFile(String filename) throws IOException {