PDA

View Full Version : Stack Overflow Error during compiling with CheckColumnConfig



mark01635
24 Jun 2009, 7:52 AM
Hi,

I am having a problem, when I add a CheckColumnConfig to my code, I get a stack overflow error during the compilation. Any ideas?

public ContentPanel CreateFolderView(String source, ArrayList<ContactEntry> list) {
ArrayList<BaseModelData> contactData = new ArrayList<BaseModelData>();
// Get the data
for (ContactEntry contact : list) {
BaseModelData bmd = new BaseModelData();
String contactString = "<b>"+contact.getName() + "</b><br>";
if (contact.getStatusIcon().equals("grey")) {
contactString += "<font color=\"d0d0d0\">" + contact.getStatus()+"</font>";
} else {
contactString += contact.getStatus();
}
bmd.set("name", contactString);
bmd.set("image", "<img src=\"images/Email/users/" + contact.getName().toLowerCase() + ".jpg\" width=\"34px\" height=\"34px\" />");
bmd.set("statusIcon", "<img src=\"images/Email/" + contact.getStatusIcon() + ".jpg\" width=\"20px\" height=\"20px\" />");
contactData.add(bmd);
}

// Build the panel for this folder
ContentPanel cp = new ContentPanel();
cp.setWidth(245);
cp.setHeight(maxHeight - 5);
cp.setAutoHeight(false);
cp.setScrollMode(Scroll.NONE);
cp.setHeaderVisible(true);
cp.setHeading(source + " address book (" + contactData.size() + ")");
cp.setCollapsible(true);
ArrayList<ColumnConfig> configs = new ArrayList<ColumnConfig>();

CheckColumnConfig ccf = new CheckColumnConfig("selected", "Selected", 30);
configs.add(ccf);
ColumnConfig column = new ColumnConfig();
column.setId("image");
column.setHeader("");
column.setWidth(50);
configs.add(column);
column = new ColumnConfig();
column.setId("name");
column.setHeader("");
column.setWidth(135);
configs.add(column);
column = new ColumnConfig();
column.setId("statusIcon");
column.setHeader("");
column.setWidth(30);
configs.add(column);
ListStore<BaseModelData> store = new ListStore<BaseModelData>();
store.add(contactData);
ColumnModel cm = new ColumnModel(configs);
grid = new Grid<BaseModelData>(store, cm);
grid.setWidth(245);
grid.setHeight(maxHeight - 5);
grid.setHideHeaders(true);
grid.setAutoExpandMax(0);
grid.addPlugin(ccf);
cp.add(grid);
return cp;
}

The error is:

Compiling module org.yournamehere.Main
Worker permutation 1 of 5
[ERROR] Unexpected internal compiler error
java.lang.StackOverflowError
at java.io.ObjectInputStream$BlockDataInputStream.read(ObjectInputStream.java:2674)
at java.io.ObjectInputStream$BlockDataInputStream.readFully(ObjectInputStream.java:2698)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1936)
at java.io.ObjectInputStream.defaultReadObject(ObjectInputStream.java:480)
at java.util.ArrayList.readObject(ArrayList.java:585)
at sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.readObject(ObjectInputStream.java:351)
at java.util.ArrayList.readObject(ArrayList.java:593)
at sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
...
at sun.reflect.GeneratedMethodAccessor58.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at java.io.ObjectStreamClass.invokeReadObject(ObjectStreamClass.java:974)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1849)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1329)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:1947)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1871)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1753)
[ERROR] Unrecoverable exception, shutting down
com.google.gwt.core.ext.UnableToCompleteException: (see previous log entries)
at com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.logAndTranslateException(JavaToJavaScriptCompiler.java:610)
at com.google.gwt.dev.jjs.JavaToJavaScriptCompiler.compilePermutation(JavaToJavaScriptCompiler.java:207)
at com.google.gwt.dev.CompilePerms.compile(CompilePerms.java:181)
at com.google.gwt.dev.ThreadedPermutationWorkerFactory$ThreadedPermutationWorker.compile(ThreadedPermutationWorkerFactory.java:47)
at com.google.gwt.dev.PermutationWorkerFactory$Manager$WorkerThread.run(PermutationWorkerFactory.java:72)
at java.lang.Thread.run(Thread.java:619)
[ERROR] Not all permutation were compiled , completed (1/5)
C:\Users\mark\Documents\NetBeansProjects\WebApplication1\nbproject\build-gwt.xml:15: Java returned: 1


If I comment out the CheckColumnConfig lines, it compiles fine.

Mark

hendricd
24 Jun 2009, 9:48 AM
@mark01635 -- Please post your code frags in [code /] tags. Moving this to GXT Forum...

micgala
24 Jun 2009, 11:25 PM
Hi.

Take a look into this thread, it will help you:
http://code.google.com/p/google-web-toolkit/issues/detail?id=3510&can=5

Regards,
Michel.