Debug.properties

From MeLibraries Wiki
Revision as of 11:56, 8 November 2013 by Eplils (Talk | contribs) (Created page with "Whose contents should look like this: <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd"> <properties> <entry ke...")

(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search

Whose contents should look like this:

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
<properties>
  <entry key="return-code">0</entry>
  <entry key="stdout">User created successfully.</entry>
  <entry key="stderr">report completed in 0.12ms.</entry>
  <entry key="message-format">symphony-api</entry>
</properties>

As you can see above you can create your own response messages as if a real ILS was responding to requests. The DummyRequestBuilder will also provide a customer formatter of the correct type if it can. The down side is that you need to restart the Metro server when ever you change any property file. The return code is the integer that a Unix or Windows command would return on exit. The stdout is what you would like to return from the requested command if it had run on the ILS. The stderr is any error messages you would like to pass. If you do a exception is thrown that will display that is returned along with the result. The message-format tells the DummyRequestBuilder what type of results these are for interpretation and for potentially creating a customer formatter.