Community
Participate
Working Groups
Steps to reproduce 1. Create a new Web 2.0 project 2. Create a new RUIHandler. 3. Open the RUIHandler in VE, an error occur. The error message is document.write("Could not open /TestRUI/test.html"); 4. Deploy the project, the RUIHandler html file is not generated. This defect seems caused by a change maded to Generator.java which move the makeContext from generator constructor to initialize method.
H
Created attachment 210564 [details] part fix
Hi, Jeff This is caused by the generator framework changes, I made a part fix, it can only solve some of the problem. but I met a problem, with the fix, it shows that the TemplateFactory can not find suitable template for generation, could you help to look at this problem, I think it is deep in the generator framework. java.util.MissingResourceException: Can't find bundle for base name , locale en_US at java.util.ResourceBundle.throwMissingResourceException(Unknown Source) at java.util.ResourceBundle.getBundleImpl(Unknown Source) at java.util.ResourceBundle.getBundle(Unknown Source) at org.eclipse.edt.mof.codegen.api.TemplateFactory.load(TemplateFactory.java:68) at org.eclipse.edt.gen.Generator.initialize(Generator.java:53)
fixed. please resync on everything
Hi Jeff I use the latest code and still get problem when open VE, exceptions throws. Does your fix can solve the problem? Please help to look at it, thanks java.lang.NullPointerException at org.eclipse.edt.gen.javascriptdev.ide.JavaScriptDevGenerator.generate(JavaScriptDevGenerator.java:39) at org.eclipse.edt.ide.rui.utils.WorkingCopyGenerationOperation.generateParts(WorkingCopyGenerationOperation.java:158) at org.eclipse.edt.ide.rui.utils.WorkingCopyGenerationOperation.generate(WorkingCopyGenerationOperation.java:131) at org.eclipse.edt.ide.rui.utils.JavaScriptPreviewGenerator.generateJavaScript(JavaScriptPreviewGenerator.java:121) at org.eclipse.edt.ide.rui.server.EvEditorProvider.generateJavaScript(EvEditorProvider.java:311)
fixed. resync on everything
Hi, Jeff I reopen it because I find a problem, in some place, xxx == Boolean.TRUE or xxx = Boolean.FALSE are used. for example, in line 58 of FieldTemplate.java, there is statement: if (veEdit != null && veEdit == Boolean.TRUE && CommonUtilities.isRUIWidget(field.getType())) it will not return true when event veEdit is true. That is because the "==" will compare the object id, not the object content, change it to veEdit.equals(Boolean.TRUE) will solve the problem. I did a search and found that there is a lot of xxx == Boolean.TRUE or xxx = Boolean.FALSE in the edt code. I think they need be corrected and tested. Thanks
I made those changes you mentioned below. Thank you. Please resync on everything and try again. I have trouble getting this code to display anything, and I do not know where to look. If you need other changes, let me know.
Is there a reason that a Boolean value of true is not using Boolean.TRUE? The Boolean constructor should never be used, always use Boolean.valueOf() to prevent creating unnecessary objects. (Same can be said for many other core types like Integer, Long, etc)
Verified in build 0.8.0.v201202190901-1Co-FjuJ6QMNRcrynsZh8h8C