Easy toString/equals/hashcode

Jasper 6

A simple, standard and reusable way of creating toString, equals and hashcode methods in your classes/beans can be found in the jakarta commons.lang package: import org.apache.commons.lang.builder.EqualsBuilder; import org.apache.commons.lang.builder.HashCodeBuilder; import org.apache.commons.lang.builder.ToStringBuilder; import org.apache.commons.lang.builder.ToStringStyle; public class BaseBean { public String toString() { return ToStringBuilder.reflectionToString(this, ToStringStyle.MULTI_LINE_STYLE); } public boolean equals(Object o) { return […]

New Oracle JDBC driver

Jasper 1

After getting a weird NullPointerException using Transaction.commit() in Hibernate during an insert (eventually calling PreparedStatement.clearParameters() which was the source of the exception), it turned out that the JDBC driver in classes12.jar is outdated, and will not work on JDK1.4 and an Oracle 10g database. Download the new drivers here to […]

Formatting HTML forms part II

Leon van Tegelen

After my post on HTML forms yesterday I was fooling around with the fieldset and label tags. Both seem quite usefull! But Internet Explorer is really quite bad at rendering the fieldset. My 4-year old daughter does a better job of coloring inside the lines Mozilla Firefox is much better […]

Hibernate kickstart

Jasper 4

A quick’n dirty tutorial-by-example for Hibernate: (Using one table, an Oracle9+ database and Hibernate2) 1) download the Hibernate distribution 2) put these jarfiles in /WEB-INF/lib: hibernate2.jar (hibernate core) cglib-full-2.0.2.jar (runtime class-enhancing) dom4j-1.4.jar (xml reading) ehcache-0.9.jar (objectcache) c3p0- (connectionpool) jta.jar (transactions)

Databases for absolute beginners


Preparing slides for a presentation on Open Source Database Systems, I stumbled upon Open Source Database Systems, a neat 15 page PDF document, introducing (open source) databases, SQL, hardware requirements for database servers and concepts such as ACID. If you are new to databases, this document can get you started […]

Formatting HTML forms

Leon van Tegelen

Allthough not earthshaking there is a nice article on the devshed about formatting HTML forms. Click here The highlights for me are the tabindex, the accesskey and the fieldset. In one of our projects we built an HTML application with a lot of data entry. The users quite rightly were […]

JDBExplorer: a test-drive

Alex Nuijten 6

Even though I started a journey into the realms of Open Source software available for Oracle , I’m taking a small detour now. JDBExplorer was suggested to me via a comment on Oracle Open Source: TOra (toolkit for Oracle). As promised I have taken a look at it and now […]

Use JAX-B or Castor for document-style encoding?

admin 7

For my Open Source project, I want to expose a stateless session bean (SLSB) as web service using JBoss 3.2 and Axis 1.1. Now I’m wondering whether to use JAX-B or Castor for my document-style encoding, since the information I found in “Create Web services using Apache Axis and Castor” […]

Oracle Open Source : FoReDoclet

Alex Nuijten 26

Everybody knows it. Documentation is essential. Most people hate two things about it. The first one is to create it, the second to read it. The Java community has JavaDoc. This takes care of both objections. Generate the documentation so you don’t have to write it. You still have to […]

Free J2EE and XML Development book

admin 11

Four your information, the book J2EE and XML Development by Kurt Gabrick and Dave Weiss can be downloaded for free at the serverside.com. Topics include Java and XML (e.g. JDOM vs. DOM, JAX-B), XML & persistency and XML & application integration. [edit jasper] Free service for the _really_ lazy: here’s […]

The power of CSS at work

Leon van Tegelen 3

If you want to see the power of Cascading Styles Sheets at work, Check out this site. It randomly generates styles to give the website a new “skin”. Just press “refresh” a few times http://www.strangebanana.com/generator.aspx Another very good site is www.alistapart.com. It provides many CSS based solutions. For example menu’s […]