commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gary Gregory <ggreg...@seagullsw.com>
Subject [lang] new ToStringStyle inner class?
Date Fri, 14 Nov 2003 18:34:57 GMT
Hello,

I find myself using the following pattern which I've placed in a class. I am
wondering if anyone else uses this kind of ToStringStyle and whether or not
it could be added as another ToStringStyle inner class.

/**
 * A ToStringStyle which uses a short class name and no hash code.
 */
public final class ShortPrefixToStringStyle extends ToStringStyle {
    public ShortPrefixToStringStyle() {
        this.setUseShortClassName(true);
        this.setUseIdentityHashCode(false);
    }
}

Gary

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message