Amazon Links

Thursday, May 06, 2004

I was just getting under the eventing support in java from a developer persepective. I wanted to define my own eventing system for a asynchronous response problem.

An good Tutorial on swing eventing is Lesson: Writing Event Listeners.
The important classes in this case are :-
  • EventListener
  • EventObject
The above classes are well explained in User defined Event Listeners Article. But the story doesn't end here,
the other eventing classes that i saw are the following:-
  • javax.swing.event.EventListenerList
  • java.util.EventListenerProxy



Now the important point is that both EventListerList and EventListenerProxy can play an important role in the implementation of the java based eventing solution.

So why are they not defined in java.util.* or say java.util.events.* ?

It seems a Generic Eventing Base has never been of importance to JDK Developers. (A possible project !!).


I leave you thinking for the same.

Tuesday, March 23, 2004

My First Blog on JAXB

Well processing the uddi v2 schema with JAXB is not straightforward.
JAXB tries to map each element, complextype, simpletype into a jaxb class. And v2 xsd contains some of these elements with the same names. As a result, it leads to an overlap in names of generated classes and hence you see the Error messages.

To overcome this problem, we need to customize the JAXB using Customization of JAXB Bindings.
See the Sample Code Nsure Uddi Project at Forge . Binding for JAXB Code Generations of uddiv2.xsd



The customization above handles the issue of duplicate class names. which results in the error reported.
Note: You need to include the above customization while generating the JAXB classes.