OBOE.properties
How the package searches for the properties file
When the OBOE package needs to read the OBOE.properties file it looks in four system objects.
- local directory. This is the directory in which you started an OBOE application or the an application
that will use the OBOE package. So if you are using a Servlet then the package will look in the
directory in which the Servlet was started in.
- user.home directory, as defined in the Java properties file
- java.home directory, as defined in the Java properties file.
- classpath environment variable. Using this you can place the properties file in a directory or
a jar file.
The OBOE.properties file contains several parameters.
- If you are just using the EDI parser or the
Valid XML parser
you only need to be concerned with one, xmlPath.
- If you are using the Well Formed XML parser you need to
be concerned with two properties, xmlPath and another identifying known transactions sets.
- If you are using the Server/Servlet portion of the package then you will
need to refer to all of the properties.
Property definitions
- xmlPath
- This identifies to the package the location of the XML rules files. End the
value string with a '\'.
- identifying known transaction sets (not the actual property name)
- This is used for the well formed XML parser. Since the XML document does not contain
the Transaction Set id but the short description of the XML document, the OBOE package
needs to make a cross reference back to the transaction set id. Remember the package
uses the transaction set id to locate the rules file.
For example if your application needed to parse an well formed XML document containing
X12 invoice data then:
- the well formed document would identify the transaction set with <Invoice> inside
of the XML document.
- to make the reference to the OBOE rules 810 file (which are for X12 invoices) the
OBOE.properties file would need an entry such as:
Invoice=810
- then when the well formed parser code finds the "Invoice" text, it attempts to find
the "Invoice" property and gets it value.
- using the 810 value, it then asks the transactionSetFactory class to get it an
instance of the 810 rules file.
Extended Edition - Property definitions
Extended Edition OBOE also includes the ability to load values into dataElement from the
properties file. Working in conjunction with 'default' node (child to the dataElement node)
in a transaction set
rules XML file, you can point to any OBOE.property variable. This includes making your own variables
used by your application.