Skip to Content
0
Former Member
Sep 07, 2005 at 01:16 PM

Accessing the enum of a simple data type (dictionary)

43 Views

Hello,

so I created a simple data type "LogLevels", entered some enumeration values and I generated a class representation:

public class LogLevels

{

private String name = "";

private LogLevels(String name) {this.name = name;}

private static final HashMap enum = new HashMap();

...

static { // fill enum ... }

...

}

Sure I can simply link the simple data type to a list box, which is nice, but how do I access the list (enum) from a model class? I was expecting a generated method something like this:

public HashMap theCollection() {

return enum;

}

I guess there must be some other way to access the list from a model class - anyone mind telling me how?

Thanks in advance,

Troy Holly