Hi everyone
I'm using GWT 1.5.1, I have:
public enum EnumAppState implements Serializable {
currentModule,
currentWindow
}
public class AppStateContainer implements Serializable {
private HashMap<EnumAppState, String> map;
public AppStateContainer() {
map=new HashMap<EnumAppState,String>();
}
/* other methods */
}
and class AppStateContainer goes throught RPC serialization fine, but
when i change HashMap to EnumMap like this:
public class AppStateContainer implements Serializable {
private EnumMap<EnumAppState, String> map; /* causes compilation
ERROR*/
public AppStateContainer() {
map=new EnumMap<EnumAppState, String>(EnumAppState.class);
}
/* other methods */
}
GWT give mi compilation error: "[ERROR] Type '(..).AppStateContainer'
was not serializable and has no concrete serializable subtypes"
EnumMap is emulated by GWT, why serialization won't work? Are any
performance differences in implementation between EnumMap and HashMap
in GWT emulation?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Google Web Toolkit" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/Google-Web-Toolkit?hl=en
-~----------~----~----~----~------~----~------~--~---