Changes for page WOLips-Eclipse beginner mistakes and questions
Last modified by Ray Kiddy on 2010/02/27 14:51
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -1,6 +1,6 @@ 1 1 This document tries to catch the errors that every beginner seems to have to go through before reaching Eclipse/WOLips nirvana. The path is narrow and slippery, but thou shalt be rewarded.... 2 2 3 -{{toc }}{{/toc}}3 +{{toc/}} 4 4 5 5 = Common errors = 6 6 ... ... @@ -18,7 +18,7 @@ 18 18 19 19 go to /Applications/Utilities/Java/J2SE 5.0/Java Preferences. Select J2SE5.0 20 20 21 -[[image:JavaRunTimeApplicationSettings.png]] 21 +[[image:attach:JavaRunTimeApplicationSettings.png]] 22 22 23 23 == The second most common error == 24 24 ... ... @@ -26,7 +26,6 @@ 26 26 27 27 {{tip}} 28 28 The following is somewhat out of date - in general terms it is still true but (as of mid-Feb 2009) Eclipse 3.4(.1) is the required version for (nightly and stable) WOLips, and WOLips nightly is around build number (3.4.)5676. 29 - 30 30 {{/tip}} 31 31 32 32 Eclipse 3.3 is a big, big project. It uses lots of frameworks. Sometimes these frameworks are already in some way available in your environment, but they are old versions, that do not do the expected thing in Eclipse. I had the experience that the help did not start in the browser. If that happens to you, remove all the jars of which you are not sure why they are there in /Library/Java/Extensions. You do not have to remove things like frontbase.jar, postgresql.jar etc. ... ... @@ -39,7 +39,7 @@ 39 39 40 40 WOLips updates often. There is a stable version, (4118) that should be used on Eclipse 3.2.2, the nightly version is where it's at now for 3.3 (Officially released 29th of june 2007). It is used in production by the wonderful people from MDimension who develop WOLips and other WebObjects developers. If something breaks in nightly, it gets fixed immediately. They depend on it themselves. 41 41 42 -[[http://webobjects.mdimension.com/wolips/nightly/]] should be in your Eclipse update site, under Help->Software Update->Find and install->Search for new features to install 41 +[[http:~~/~~/webobjects.mdimension.com/wolips/nightly/>>url:http://webobjects.mdimension.com/wolips/nightly/||shape="rect"]] should be in your Eclipse update site, under Help->Software Update->Find and install->Search for new features to install 43 43 44 44 == The fourth most common error == 45 45 ... ... @@ -55,9 +55,9 @@ 55 55 56 56 = User questions = 57 57 58 -== I created a component but I don't see it in the Components folder == 57 +== I created a component but I don't see it in the Components folder! == 59 59 60 -When you create a new component, it will put the component into the highlighted folder in the Package Explorer. 59 +When you create a new component, it will put the component into the highlighted folder in the Package Explorer. For example, if the current highlighted folder is the project name, the component will be created in the top-level folder of the project. So you will find your component there and you can move it to the Components folder. 61 61 62 62 So when you create a new component, make sure that you highlight the Components folder, or right-click on the Components folder and select New->Component, it will be created into the good folder. 63 63 ... ... @@ -65,27 +65,27 @@ 65 65 66 66 Not all the files are presented, some are filtered away. In Package Explorer (In WOLips pespective, the upper left window), go to the right corner of that window, there is a caret. Under this caret, there is a Filter option.Click on it to see what get's filtered away. 67 67 68 -[[image:filters.png]] 67 +[[image:attach:filters.png]] 69 69 70 70 As you can see, quite a lot of files are excluded from the view. 71 71 72 -[[image:FilterProperties.png]] 71 +[[image:attach:FilterProperties.png]] 73 73 74 74 == Where did all my code go? == 75 75 76 76 Suppose you suddenly ended up with something like this: 77 77 78 -[[image:StrangePerspective1.png]] 77 +[[image:attach:StrangePerspective1.png]] 79 79 80 80 Or this: 81 81 82 -[[image:StrangePerspective2.png]] 81 +[[image:attach:StrangePerspective2.png]] 83 83 84 84 Most of the times this is caused by inadvertently clicking on the menu-bar of the subwindow. That window will then fill the whole workspace.Clicking the menubar one more time will restore the view. 85 85 86 86 Or it is happened because your perspective has changed inadertently, because you clicked on a file that caused another perspective to be fired up (like Entitymodeler) You can go to the top right, where there is a place where the currently loaded perspectives are located. Choose WOLips again. You're done. 87 87 88 -[[image:chooseperspective.png]] 87 +[[image:attach:chooseperspective.png]] 89 89 90 90 == I have the right perspective, but it is all screwed up. == 91 91 ... ... @@ -97,7 +97,7 @@ 97 97 98 98 If you open a lot of projects at the same time, you'll sometime find yourself editing a few Session.java or localizable.strings files at the same time. How can you see which file from what project you are editing? There is a simple trick for that: in the Package Explorer window, click on the icon with the two arrows on it. From now on, if you select another file in the editor window, you'll be directed to that file in the project in Package Explorer. 99 99 100 -[[image:SeeFileinProject.png]] 99 +[[image:attach:SeeFileinProject.png]] 101 101 102 102 == Another app is running than I expected: == 103 103 ... ... @@ -115,21 +115,21 @@ 115 115 116 116 Select Project in Package Explorer, from menu choose Run->Run... , from contextual menu choose Run As->Run 117 117 118 -[[image:LaunchArgs1.png]] 117 +[[image:attach:LaunchArgs1.png]] 119 119 120 120 You'll get into the create,manage and run configurations window. If there are any launch configurations available in your projects, you will already see them here. If there aren't any, a new one will be created. Normally the proper settings for a WOApplication are all in place, if you have created the application from the contextual menu. See the tutorials. 121 121 122 - Note that if you are overriding a parameter supplied by WebObjects, such as WOPort or WOAutoOpenInBrowser, then you need to add the parameter settings in the Arguments tab that you see above. For example, you can add "-WOPort 55555 WOAutoOpenInBrowser NO". BUT, you also need to uncheck these entries in the "WO" tab above. If you do uncheck them, your suggestions may be ignored.121 + Note that if you are overriding a parameter supplied by WebObjects, such as WOPort or WOAutoOpenInBrowser, then you need to add the parameter settings in the Arguments tab that you see above. For example, you can add "-WOPort 55555 -WOAutoOpenInBrowser NO". BUT, you also need to uncheck these entries in the "WO" tab above. If you do uncheck them, your suggestions may be ignored. 123 123 124 124 By default these settings are stored in the workspace, not in the project. If you want to store them in the project, you have to change the settings under the "Common" tab, from "local" file to "shared file", and you can save it then in your project for future use. 125 125 126 -[[image:Launchsaving.png]] 125 +[[image:attach:Launchsaving.png]] 127 127 128 128 == I want to open EntityModeler in a new window, so it does not get in the way of WOLips == 129 129 130 130 There is a setting in the WOLips preferences, which will get your EOModel started in a separate EntityModelere window: 131 131 132 -[[image:OpenEntityModelerInNewWindowAnnot.png]] 131 +[[image:attach:OpenEntityModelerInNewWindowAnnot.png]] 133 133 134 134 == I see all that magic typing with code completion going on. How do you do that? == 135 135 ... ... @@ -137,12 +137,10 @@ 137 137 138 138 Actually, it is real magic. The trick is that it works in a contextual way. So the program knows what kind code can be expected where. For instance, if you are inside the bindings of a WOComponent, it will know which bindings are there. Just press Control-Space, and you will get the possible endings. 139 139 140 -[[image:ContextualContentAssist.png]] 139 +[[image:attach:ContextualContentAssist.png]] 141 141 142 142 {{warning}} 143 - 144 -Please note that Control-Space is also the key combo for Spotlight. You need to either change the key combo for Eclipse (Preferences->General->Keys) or for Spotlight (System Prefences->Spotlight). 145 - 142 +Please note that Control-Space is also the key combo for Spotlight. You need to either change the key combo for Eclipse (Preferences->General->Keys) or for Spotlight (System Prefences->Spotlight). 146 146 {{/warning}} 147 147 148 148 == Which shortcuts are available? == ... ... @@ -154,30 +154,30 @@ 154 154 Some general Eclipse shortcuts: 155 155 156 156 cmd-1 = Quickfix: suggest you a fix for your errror 157 -cmd-e = quick switch to other open documents 158 -cmd-space = completion, also known as content assist. This one screws up with the standard settings for Spotlight, which are also cmd-space. Some have tried to move cmd-space to something else in Eclipse, but that does not seems to be picked up everywhere. Better replace Spotlight to something else. 154 + cmd-e = quick switch to other open documents 155 + cmd-space = completion, also known as content assist. This one screws up with the standard settings for Spotlight, which are also cmd-space. Some have tried to move cmd-space to something else in Eclipse, but that does not seems to be picked up everywhere. Better replace Spotlight to something else. 159 159 160 160 Some shortcuts that are available from WOLips (gracefully donated by Mike Schrag): 161 161 162 162 Ten ShortCut Commandments for Mike: 163 -cmd-shift-t = open type 164 -cmd-shift-r = open resource 165 -cmd-shift-o = auto-import 166 -cmd-opt-r = refactor rename (global) 167 -cmd-2 r = refactor local rename 168 -cmd-opt-1 / 2 / 3 = switch between java/wod/html 169 -cmd-o = in-place outline view 170 -cmd-o o = include superclass 171 -cmd-shift-g = show references 172 -F3 = go to declaration 160 + cmd-shift-t = open type 161 + cmd-shift-r = open resource 162 + cmd-shift-o = auto-import 163 + cmd-opt-r = refactor rename (global) 164 + cmd-2 r = refactor local rename 165 + cmd-opt-1 / 2 / 3 = switch between java/wod/html 166 + cmd-o = in-place outline view 167 + cmd-o o = include superclass 168 + cmd-shift-g = show references 169 + F3 = go to declaration 173 173 174 -Another nice overview of shortcuts that Edgar Klein sent me can be found here: [[http://eclipse-tools.sourceforge.net/Keyboard_shortcuts_(3.0).pdf]]. It can be even printed out on one double page, so you can put it above your bed. 171 +Another nice overview of shortcuts that Edgar Klein sent me can be found here: [[http:~~/~~/eclipse-tools.sourceforge.net/Keyboard_shortcuts_(3.0).pdf>>url:http://eclipse-tools.sourceforge.net/Keyboard_shortcuts_(3.0).pdf||shape="rect"]]. It can be even printed out on one double page, so you can put it above your bed. 175 175 176 176 == I have the choice of doing a WOApplication or a WOnderApplication, which one should I use ? == 177 177 178 -If you use WOLips/Eclipse 3.2, or if you use a WOLips 3.3 from before December 2007, the layout for the WOApplication and for the WOnder Application was quite different. Starting in recent (December 2007 and later) builds of WOLips, the layout is the same ("WebObjects Application" use the "Wonder" layout), the only difference between them is that the Wonder-type application and framework will link to the Wonder frameworks (ERJars and ERExtensions), Application.java will extend from ERXApplication and Session.java will extend from ERXSession.175 +If you use WOLips/Eclipse 3.2, or if you use a WOLips 3.3 from before December 2007, the layout for the WOApplication and for the WOnder Application was quite different. Starting in recent (December 2007 and later) builds of WOLips, the layout is the same ("WebObjects Application" use the "Wonder" layout), the only difference between them is that the Wonder-type application and framework will link to the Wonder frameworks (ERJars and ERExtensions), Application.java will extend from ERXApplication and Session.java will extend from ERXSession. 179 179 180 -If you are using a old build of WOLips, you should use the Wonder layout, you just need to remove the references to ER if you don't use Wonder. 177 +If you are using a old build of WOLips, you should use the Wonder layout, you just need to remove the references to ER* if you don't use Wonder. 181 181 182 182 == If I right-click on an folder and select "New", I don't see "EOModel" or "WOComponent" as options. == 183 183 ... ... @@ -185,7 +185,7 @@ 185 185 186 186 == Component Bindings are Showing Errors, but No Error Is Present == 187 187 188 -This can occur for example where you are overriding ##valueForKey(..)##and so the component editor is not able to know that a keypath is valid.##~/~/VALID##at the end the association and Eclipse will stop taking this to be a bad binding.185 +This can occur for example where you are overriding {{code language="none"}}valueForKey(..){{/code}} and so the component editor is not able to know that a keypath is valid. In this case add {{code language="none"}}//VALID{{/code}} at the end the association and Eclipse will stop taking this to be a bad binding. An example follows; 189 189 190 190 {{noformat}} 191 191 ... ... @@ -197,8 +197,8 @@ 197 197 198 198 == Classpath Order == 199 199 200 -App 201 -Non-App-Projects 202 -Non-Apple-Framework jars 203 -Apple-Framework jars 204 -normal jars (everything not named Foo.framework/../Foo.jar) 197 +[App] 198 + [Non-App-Projects] 199 + [Non-Apple-Framework jars] 200 + [Apple-Framework jars] 201 + [normal jars (everything not named Foo.framework/../Foo.jar)]