Added support for custom Java App layouts.

Modified AppController and AppManager to support custom WAR directory names for Java Apps.
Fixed minor style issues.