Can you include GwtBootstrap3 in an existing GWT project - gwt

I have a project that has taken me 2 years, in my spare time, to develop (I am not a developer by trade) and has over 50 views. I have been told that to produce a better user experience and speed up my development I should use GwtBootstrap3. At this time I do not have time to rewrite the whole project so is it possible to include GwtBootstrap3 in the existing project, build new views using GwtBootstrap3 and slowly converting existing views to GwtBootstrap3?

Technically speaking the answer is Yes, follow setup guide of gwtbootstrap3. But, gwtbootstrap3 inject few default css in application on load which might can affect few of your current views. Hope you are following some kind of mvp patterns, if not first start use of it and then go for modifying existing views.

Related

Eclipse 4 RCP How to launch another plug in in a new window

I have an e4 RCP which needs all the screen real estate. I have developed a second RCP that is in effect a relatively simple single-function plug-in, with currently only one part. I want the user to be able to launch the second from the first, then terminate it, all on demand.
As I understand it, I have 3 options:
Launch a new workbench for the second, written as a plug-in. I assume this uses more resources and also has the problem that I need to track and distinguish events which will go to both.
Write the second as a model fragment plug-in that extends the first. This has the advantage that I can keep on adding to the second plug-in by declaration in the model editor. However, I believe this requires attaching to an existing container in the main model. I could add a new container to the main model and write code to flip containers in and out but it is all done in the model editor currently, and more importantly the functions carried out by the second plug-in are quite different from those of the first (main) RCP, so I fear the user will find the UI change confusing.
Use EModelService and write code to create a new TrimmedWindow and then child PartStack, and Part, and all the Handlers. I have not yet found enough documentation to fully understand the implications, advantages and disadvantages of this - aside from the obvious ones that the former declarations now have to be programmed and coupling is tighter.
It looks to me like Eclipse itself uses approach 1 for two of its menu items:
Help Contents
Eclipse Marketplace
From the UI perspective, the kind of UI separation of functions that I want to achieve is very much like these two items. Hence I am leaning to option 1.
Any corrections or alternatives?
You could possibly use a PerspectiveStack with two perspectives containing the windows for your two apps. The second app can be in model fragment.
You can then just use EPartService.switchPerspective to switch between them.

Upgrade from Alfresco 4.1 to Alfresco 5

I am evaluating the option to upgrade a project developed for Alfresco 4.1 to Alfresco 5.
The project contains mostly customisations of Alfresco Share. We have new pages but also customisations of OOTB pages (the document library for example).
I know that Aikau has been already introduced in some of the pages in Alfresco 5.
I am wondering how much of our code could be reused.
Because the customisations have been implemented using Surf, most of their logic is in webscripts. Is it possible to continue to use these webscripts with Aikau?
The biggest change made in Alfresco Share was between versions 4.1 and 4.2 when all of the WebScripts were refactored to move all the logic out of the FreeMarker templates and into the JavaScript controller (see the series of blog posts starting here). The purpose of this was to make customization easier as it enabled simple configuration tweaks as well as swapping out default Alfresco widgets for 3rd party extensions. This somewhat paved the way for the approach that Aikau then follows - namely to allow all customizations to be done through the WebScript JS controller but with Aikau the widgets are much finer grained.
Ultimately it is going to entirely depend on your customizations for 4.1. The main differences you'll find are to the header bar and to the search page. The toolbar and documentlist Surf Components were also merged to reduce the vertical space that they took up.
The main issue for other WebScript customizations will be that you'll need change how you were extending them, as code that was previously in the FreeMarker template in 4.1 will now be in the JS controller.
Aikau has already been introduce in 4.2.e, to check the full listing of functionalities developed in Aikau, check this link.
Aikau is built on top of spring surf, so most of your customisations (if not all) should still be viable. The only difficulty I think you may face is migrating your project structure from the old ANT SDK,to the new one based on maven! But this page should guide you through the use of the new SDK.

Large scale application with GWT

I'm using GWT (2.0.x) to develop a large scale and modularized application, but some modules have a lot of classes.
I'm facing a problem with GWT in development, because the DevMode it's taking a long time (processing) when I change every client-side class and refreshing at the browser.
My last option is to split more that modules, but I'm thinking to edit the GWT-DEV source code and "tell him" to do hotdeploy only on selected classes.
I have another option rather than edit GWT-DEV source code ?
Try using GWT.runAsync() to lazy load your code. If you can load only those modules that you need. You can make fairly complex web apps using GWT which run very fast. Hope you are following the MVP architecture recommended by google. Any extra information regarding the number of your classes etc will be helpful if figuring out if you need to reconsider your architecture or not.

Time to develop an option in Eclipse to modify a Java file source

I'm evaluating the possibility of developing an Eclipse plugin to modify the source code of some Java files.
The Eclipse plugin should:
add one menu option or context menu option to launch the modification process.
add a key binding
only alter the UI in that way when an editor has been open on a Java file.
the modification process would not open a dialog, or maybe, a very simple one.
the modification process would traverse the AST of the Java file and would modify it.
Considering that we have no experience with Eclipse plugins and we need spend time in reading docs, how much time do you estimate in developing that plugin?
Thanks in advance.
It's really not that difficult at all... I had students in my design patterns class doing it for an assignment (adding/removing javabean getters and setters)
See http://help.eclipse.org/ganymede/topic/org.eclipse.jdt.doc.isv/guide/jdt_api_manip.htm
[EDIT: added the following article reference]
And a great article on it at http://www.eclipse.org/articles/article.php?file=Article-JavaCodeManipulation_AST/index.html (from 2006 -- there may be a few API changes since)
Yes, writing plugins takes a little getting used to, but so does any API.
And you can modify the AST -- see the page I reference above.
(I should note that the above link is from the eclipse help, which can also be accessed via Help->Help Contents inside Eclipse -- there's a lot of good info in there, but it's just a starting point)
You'll probably spend quite some time cursing the complexity of the eclipse plugin system. There are some example plugin development projects that can be very helpful if they cover the area you're working in.
I'd say you're looking at 2-4 days of work, spent mainly getting familiar with the platform - someone with a lot of experience writing eclipse plugins would probably take no more than an hour.
However, your step 5 could be tricky. I don't know how easy it is to access and change the Java AST; my experience is based on developing an editor plugin for an exotic file format rather than Java code.
Well, the four first points are easy to achieve, even by monkey coders that look at the eclipse PDE documentation shipped with Eclipse. These can be achieve in 1 day of work, maybe 2.
The hardest point is really the fifth one and the kind of modification you expect to do. Acting directly on the editor content is simple, accessing the editor internal AST and modifying it is really a bigger challenge and I doubt that it could be achieve in less than a week by unexperimented people (it can take longer, depending of what kind of modification you want to apply).

How can one use the Web Page Editor in custom RCP application?

I want to use the "Web Tools Editor" that is part of the Web Tools Plattform in my own RCP-Application. I think i have got some understanding on the RCP plattform by now, but I still have no clue how to access the functionality of the pagedesigner (org.eclipse.jst.pagedesigner) after adding it as a dependency to my project. Has anyone some experience in adding components of the web tools plattform into an RCP-Application and can give me a hint or something?
There's a difficulty with these sorts of requests (I am, myself, trying to include this or that feature that I saw in the Eclipse IDE, every so often).
The trick is to try and identify the component you want to bring in, and then try and pull it into your project, without bringing in too many dependencies.
The first step used to be quite hard, but since 3.4 it is a matter of using the Plug-In Spy - hold down Alt-Shift-F1 on whilst your desired component is in focus should give you a tooltip showing you the class, the bundle, etc etc.
The second step is altogether more tricky and is where I usuaully fail to get any results:
if you are lucky then you can just include the bundle in the launch configuration/.product of your app. Once you hit Add Required Bundles, you are not left with 3000 bundles (i.e. your RCP is now Eclipse).
usually, this is not the case, because the Eclipse team haven't refactored the bit of code you're interested in out into an RCP safe bundle. If so, then you're going to have to do that yourself.
Again, if you are lucky then that will mean moving some classes out of the eclipse bundle into your own, including internal classes, and that will be the end of it - i.e. the dependencies of your desired functionality are all within the bundle.
If you're unlucky, then you need to isolate/reimplement the bit of functionality that is required, and change your version of the copied code.
It is hard laborious, and pretty difficult to upgrade. I realise that none of this is what you want to hear.