Update to output more nicely formatted toString() that converts $ to .

git-svn-id: https://svn.apache.org/repos/asf/jakarta/commons/proper/lang/trunk@137246 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Stephen Colebourne 2003-02-04 16:56:08 +00:00
parent 6f78d8a02b
commit 2ddf33ffc3
1 changed files with 2 additions and 1 deletions

View File

@ -156,7 +156,7 @@ import java.util.Map;
* @author Stephen Colebourne * @author Stephen Colebourne
* @author Chris Webb * @author Chris Webb
* @since 1.0 * @since 1.0
* @version $Id: Enum.java,v 1.6 2002/12/31 22:39:39 scolebourne Exp $ * @version $Id: Enum.java,v 1.7 2003/02/04 16:56:08 scolebourne Exp $
*/ */
public abstract class Enum implements Comparable, Serializable { public abstract class Enum implements Comparable, Serializable {
/** /**
@ -421,6 +421,7 @@ public abstract class Enum implements Comparable, Serializable {
if (pos != -1) { if (pos != -1) {
shortName = shortName.substring(pos + 1); shortName = shortName.substring(pos + 1);
} }
shortName = shortName.replace('$', '.');
return shortName + "[" + getName() + "]"; return shortName + "[" + getName() + "]";
} }
} }