KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > tc > object > dna > impl > EnumInstance


1 /*
2  * All content copyright (c) 2003-2006 Terracotta, Inc., except as may otherwise be noted in a separate copyright
3  * notice. All rights reserved.
4  */

5 package com.tc.object.dna.impl;
6
7 public class EnumInstance {
8   private final ClassInstance classInstance;
9   private final UTF8ByteDataHolder enumName;
10
11   public EnumInstance(ClassInstance classInstance, UTF8ByteDataHolder enumName) {
12     this.classInstance = classInstance;
13     this.enumName = enumName;
14   }
15
16   public ClassInstance getClassInstance() {
17     return classInstance;
18   }
19
20   public Object JavaDoc getEnumName() {
21     return enumName;
22   }
23
24   public String JavaDoc toString() {
25     return "Enum(" + classInstance + ", name: " + enumName.asString() + ")";
26   }
27 }
28
Popular Tags