Showing posts with label netbeans. Show all posts
Showing posts with label netbeans. Show all posts

Thursday, September 02, 2010

Creating a Simple Database Client in JavaFX Composer

If you think that a database application is a 2 buttons 2 values 1 screen plate: this tutorial is for you...

http://netbeans.org/kb/docs/javafx/database-client.html

WE NEED A DECENT FRAMEWORK FOR BUSINESS APPLICATIONS !


- Text editor, spreadsheet - Even basic stuff
- Reports engine
- Client Server or Web with Plain Ajax
- Easy DB Access and GUI
- i18n really built-in not just a few labels translations...
- Application Framework - GUI / DB / Login / Permissions
- Application Module
- Integrated with IDE support
- Short and soft learning curve !

Thursday, July 08, 2010

Java RIA... getting impressed by... Apache Pivot

More than a year ago, I wrote a few articles on Apache Pivot. Well, my enthusiasm was very limited.


We are now in the process of re-writting a Delphi based application. Ideally using Java...

We could use simply Swing. But note, that the Swing application framework went back to life before to re-die again...

We checked OpenSwing. It is a good library, which adds a lot of good things on top of Swing. Useful but the look & feel... and a lot of code for just a little app.

To ease things, I looked at Netbeans as a platform. Overkill in many cases and it solved many problem we don't have and ignore those we have... Including we need a short learning curve and  among the big issue dynamic localization - language switching http://netbeans.dzone.com/multilingual-netbeans-platform-applications.


Also I spent a bit of time reading about JavaFX. Nice little language, but I cannot find anything that looks like an enterprise feature. Again the old Sun syndrom, we found a nice idea, lets market it against inacessible competition and consider our installed based as supreme idiots... bringing them features they never asked.


So I checked again Pivot - now version 1.5 and I AM IMPRESSED.

Documentation is very much improved, so that makes the purpose very much understandable.  Plus you have a bunch of very good examples.

The graphical glitches are gone ! Performance looks pretty good.

Most of the things are there and well designed, Web services, binding, event handling, scripting in the UI definition (any JVM language...).

And yes, a good looking mechanism for static localization.

The design is clean and nice (not very fancy but it is good loooking). It is designed to be skinnable, so we can expect much more funny things sooner or later.

You can build GUI using a straightforward XML based language (the layout can then get transferred to the client and transformed into GUI -> yes in fact this what Open ERP Python APP does...) .

So it is a cool toolkit and it appears much more oriented towards enterprise apps than FX. So my new acronym Rich Enterprise Internet Application that fits for Pivot but no go for FX.

The unfortunate thing... it is not compatible with Swing (I can live with that) but I need a minimal kind of word processor for my app (that I have with Swing and EditorKit stuff). Too bad, nothing is perfect... But keep going Apache Pivot you are heading to the right direction. At least I am getting convinced!

Just a link so you can check (you need Java plugin to get the examples running): http://pivot.apache.org

Friday, January 08, 2010

Some JPA for a tiny library management app

I am part of the parents comittee of my kids school. Among our projects we are trying to setup a small library for kids.

I like helping the community but  these projects are challenging because we run on a nearly zero € budget.

So I proposed myself to manage the book catalog. I built a year ago a small Java app for printing stickers with barcode (an opportunity for doing raw printing). Now I am working on the application to mange book leases.

I took this opportunity to use JPA for building a Swing desktop application. The databasee has been designed directly with MySQL. I imported the schema and Netbeans (6.8) generated the persistene unit and the Java classes. Good but the generation was a bit disappointing. Foreign keys (many to one) were not implemented as reference to Java objects, so I had to code this myself.

What I like with JPA is the feeling to be isolated from the DB specificities without being tight to one JPA provider. I switched just to try from Hibernate to TopLink to EclipseLink, it works great.

Building Java Swing application is rumored to be a pain. With Netbeans it is relatively confortable.... You can drag and drop components on forms as you do with Delphi or VB.

The interface builder is doing something very nice. By looking at how you position components it deduces rules you would like to see respected. Nice, things get properly aligned and are well adaptative when you expand windows. Conceptually that's perfect.

Yesterday, I was almost finished with the app, being able to lease out and log book returns... Unfortunately I tried to fix a couple of glitch in the status bar of the app. What I did? Don't know. The net result is that after three hours of work last night, my entire layout collapsed and the app is basically unusable at this stage...

Thursday, October 08, 2009

Experimental plugins for netbeans

http://deadlock.netbeans.org/hudson/job/nbms-and-javadoc/lastStableBuild/artifact/nbbuild/nbms/updates.xml.gz

Configure this url in the list of the update centers...

Well, it contains at least one perk... a plugin that mimize scanning of your project!

Friday, July 10, 2009

First steps with Python support in Netbeans 6.7

Python support is being added to Netbeans.

Install Netbeans 6.7 (in my case the bundled JDK did not installed, so I had to install the JDK speartely) then in the list of plugins install the Python module.

http://www.netbeans.org/kb/docs/python/temperature-converter.html

The install will bring you Jython as a first Python platform. I will keep that for further study. I then installed the Cpython 2.6. Restarted the Netbeans platform and to my great surprise Tools/Python plaftorms auto detected the new Pyhton install !

I created a project, but there, a problem occured when trying to debug. The message was a bit hard to decode. I saw file names truncated (under Windows, the default projects directory is under 'Documents and settings'. I changed the location to avoid spaces (something I always remind around me - don't put space in file names) and it works (I mean I can debug a 2 lines long Python program.

Monday, May 11, 2009

Netbeans & Spring - refactoring not easy as it should be

Well, may be you think it is caused by poor design... But I wanted to change the way a few objects were named modify the packaging structure in a soon to be released application. Refactoring with Netbeans is usually easy as the IDE changes properly references for you. Well it does in the Java code but not in the Spring XML definition !

Too bad and now hours of checking ahead !