Is there a good step-by-step tutorial for using datanucleus and maven? - datanucleus

I have a basic java-maven-wicket project and need a persistence layer. I want to start with something fairly simple and low maintenance so I can concentrate on the business logic. I've been using db4o directly but have been having some issues and would like to move to using datanucleus as it supports both db4o or regular rdbms. Unfortunately the docs are a bit of a mess and none really show you how to set up a project from scratch - at least not with maven.
Does anyone know of a good tutorial? Are there any books on Datanucleus?

No idea what "a bit of a mess" is since you don't define what is not understandable to you.
Obviously if you just clicked on "Guides" in the docs (top level navigation) then you could just see "Use with Maven2".
Or then you could go to the docs and just type in "Maven" in the search box, and use the first link on the page to find the exact same doc.

Related

Hippo custom essential plugin creation

How do we add our own plugin. Lets say a new add-on or feature which can be installed and used. How do we develop that? I am sorry i am new to this.
Kindly help
Depending on your needs, I suggest you check out:
https://documentation.bloomreach.com/14/library/concepts/open-ui/introduction.html
You can also create various plugins more like the native functionality. Adding such to essentials is described here:
https://documentation.bloomreach.com/14/library/essentials-plugins/overview.html
That doesn't tell you how to create a plugin however. Essentials is just a helper application, the plugin can be various things from services, to configuration, to document types, to hst components... All of that requires some knowledge of the internals of the system. Look around the documentation, you can see how to create various things like workflows, perspectives, and more.
A plugin is no more than a collection of code and configuration bundled together. It could be a frontend thing or a backend thing. So I can't simply tell you how to create them. It can be quite difficult, depending on what you want, to create a plugin. Look into the code of some plugins, you will see that it is basically a java project with some configuration that can be found by the system on startup.
You might want to ask more specifically on what exactly you want to develop. That could lead to more specific advice. It can be daunting when you are starting to work with the cms. With experience it does start to make sense.

GUI Platform choice: Google GWT, SmartGWT, ExtGWT and SmartClient

We are in the process choosing a new GUI platform. Ive been looking at subj. but are a bit confused. Could someone please refer to at tutorial or blog that makes a qualified comparison.
Thanks.
Nikolaj G.
We've used SmartGWT for a couple of projects and it's ok but there are tradeoffs:
PRO:
Makes it easy to write a web app that looks and works like a rich client GUI.
Don't have to know any Javascript. SmartGWT coding is pretty similar to Swing coding, which is good if you already know how to do that.
CON:
Unless you do a lot of work tinkering with the look and feel, your app won't look very web-like, it will look like a rich client app running in a browser. You may not care about this.
It's a pretty heavyweight library which has to download large .js files to get going.
We found it difficult to control the layout of form controls precisely, but that might just be our inexperience.
I think you should fully understand what GWT does and what your projects needs are first and foremost. There wont be a source that will adequately compare them for your specific needs.
Start with the wikipedia http://en.wikipedia.org/wiki/Google_Web_Toolkit
Here is a comparison of SmartGWT vs GWT
http://www.theserverside.com/discussions/thread.tss?thread_id=60186
If interested in AJAX RIA Frameworts, below analysis is for you
Before starting new GUI for our new project arrival, I made some research.
Here are my findings (remove spaces from "http: // "; bcoz stackoverflow is preventing me to do so :)):
Prototype framework favorable links:
http://en.wikipedia.org/wiki/List_of_Ajax_frameworks
http://www.javabeat.net/articles/12-comparison-of-ajax-frameworks-prototype-gwt-dwr-and-1.html
http://www.devx.com/AJAXRoundup/Article/33209
Dojo framework favorable links:
http://blog.creonfx.com/javascript/dojo-vs-jquery-vs-mootools-vs-prototype-performance-comparison
jQuery framework favorable links:
http://blog.creonfx.com/javascript/mootools-vs-jquery-vs-prototype-vs-yui-vs-dojo-comparison-revised
Test speed of different RIA frameworks:
http://mootools.net/slickspeed/#
More comparasions:
http://en.wikipedia.org/wiki/Comparison_of_JavaScript_frameworks
http://jqueryvsmootools.com/#conclusion
Out of all these findings I started using SmartClient 5. Initially we faced some issues but as SmartClient matures I find it interesting in many terms:
1. APIs doc help and examples
2. Flexible controls
3. Forum
Today I am working on SmartClient 8 and few on my GUIs are in production running successfully. Actually the great help with SmartClient is that you find every thing at one place. No need to dug many other sites that is hard to do for any other open source RIA framework.
So my choice is no doubt SmartClient.
Thanks
Shailendra (shaILU)

Eclipse RCP terminologies and concepts

I am just starting to develop some application using Eclipse RCP. I was able to hack out a prototype by reading some tutorials. Although I was able to hack out some working code, I found myself shaky on some of the RCP concepts like:
What is a page? I see a lot of getActivePage() API calls, so I am assuming there can be multiple pages am I correct?
In the IWorkbechPart API there is an API called getSite(), which is being use a lot, but I am not sure what is a "site"
The above are just a sample of questions I am having, so it would really help me if someone can point me to some articles explain these type of concepts (I did google around without success).
I would also appreciate it if someone can point me to some articles that can educate me on how to write clean RCP code; kind of like the "Effective Java" for RCP.
You may want to check this as well:
Take a look at the JavaDoc for the Interfaces, they are well documented and give you an idea of the terminology. For example:
What is a page?
Look at the Javadoc at org.eclipse.ui.IWorkbenchPage
called getSite(),
Look at the Javadoc at org.eclipse.ui.IViewSite

Good idea / Bad idea (/other ideas ?)

I have recently been asked to make an Eclipse Rcp view that would be "pretty".
In that purpose I had fist looked at Java2D (after my boss advised me so) before the client's query turned to be more like
"It would be smooth if you could do some flash or something ..."
From there JavaFx seemed appealing to me however I never had a chance to use it before. I then were wondering if before to dive "head first" anyone (who would have preferably used it seriously) had any advice, warning or any constructive comment to do about using this product in an RCP view (so based on SWT).
I really long to know if JavaFx meets it's promises.
Thanks in advance and have a good day !
[EDIT]I dont want an Eclipse Fancy skinning or to make views appear with light effects or in a CompizFusion way,
What I want is to display fancy animations and pretty visual effects within a specific view that will be called sometimes. (Sorry I wasn't clear in the first place :s)[/EDIT]
*I'll pass on the "What's pretty and what's not ?" and other "Tastes are a personnal thing" debates, here "pretty" simply means to qualify a view containing convoluted transparancies and subtle animations ...
Eclipse RCP can also be customized in the way it looks, e.g. when you dont want to have the Eclipsi-L&F. Its called Presentation API, I saw a quite amazing UI once in a presentation but I cannot find it right now. Anyway, I just want to point you the direction, since I personally havent used this API (yet).
There are also some "skins" available for download.
Nebula
MP3 Manager
EDIT: Just found the slides. It goes quite into detail, but when you have a look at the last slide...it doesnt look like the Eclipse you know :-)
JavaFX uses Swing as default layout engine, so you'll gain nothing using it rather than Java2D.
On the other hand, using either your home-grown toolkit or Swing is generally a bad idea when working with Eclipse, as it already embeds the SWT toolkit. The main advantage of SWT over Swing is that it use the OS native widgets. Using another toolkit will lead to the following issues:
Poor integration with Eclipse look&feel.
Poor integration with Eclipse views and editors management.
The answer is simple. No, you can't use JavaFX yet. The problem is that JFX script can't be embedded into Swing nor Eclipse SWT. We already know about such an issues. (The is some kind of hack how to embed JFX into Swing APP only.)

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).