Skip to main content

Posts

Showing posts from June, 2008

Java Design Patterns

Today i had the pleasure to present a session at the monthly Java User Group Malta meeting ... its always a pleasure to meet other Java Developers in our community and aspiring students. Click on the post tile to link to the presentation ... Regards and good luck guys ... hope to meet again for other sessions.

Java Web Application Properties

One of the most common application requirements is usually to create a central place where to keep application properties or application settings. These properties are normally settings or general properties that are applied to the application during runtime. A number of options exist, including creating string properties on your application server and accessing them as JNDI resources. However one of the still most practical approaches is to keep a properties config file with a simple propertyName =propertyValue   type of structure. The example below is an example of an Application Config class that loads the application properties from a file named config.properties which is stored in the root of the source packages (root package) and hence automatically deployed with the application jar file during the build process. import java.io.IOException; import java.io.InputStream; import java.util.Properties; import java.util.logging.Level; import java.util.logging.Logger; public cl...