Posted by editor
on January 30, 2007 at 7:00 AM PST
Giving your objects the functionality they need... also:
Feature Article: Separating Concerns and Advising Domain Objects
Java Today: Struts-like portlets, JNI for NetBeans tutorial, and Elliotte Rusty Harold on properties
Weblogs: Still waiting for Java SE 6 on Mac, test harnesses, and Rich on tour
Forums: ME for Nokia 770/N800, why France is near Antarctica, and beans binding
Giving your objects the functionality they need
I was a little hesitant to reuse our "Aspect-Oriented Programming" series tile on today's Feature Article , because while its approaches are in the spirit of providing "advice" to address cross-cutting concerns throughout a program, author Eric Batzdorff found AOP an unneccessaily invasive mechanism for his needs. Still, though, the motivation is similar to that of AOP developers, and the approach of developing runtime proxy objects is an interesting alternative that should be considered by anyone inclined to go down the AOP road.
The gist of his article, though, is that what works for one object in sample code may not be a suitable approach for many objects in your business logic. In the conclusion to Separating Concerns and Advising Domain Objects , he writes:
Advising objects to separate concerns is an extremely powerful pattern. Spring-like approaches to AOP are fantastic choices if few instances of the advised class need to be created. However, many domain objects do not fall in this category. AspectJ is a full-featured AOP implementation that is designed to advise both singletons and domain objects. However, AspectJ is not a trivial technology to bring into a development environment, so knowing alternatives is a good thing. For advising domain objects, we explored object pooling, class extension, and using the Decorator pattern, and there are undoubtedly others. Depending on the scenario, each approach enables a separation of concerns that object-oriented programming and aspect-oriented programming advocate.
Take a look at the approaches and see what you think -- do the AOP alternatives suit your needs to decouple your objects, and are they maintainable?
In Java Today ,
the PORTIONS project, short for PORTlet actIONS, is a framework that can be used to create JSR-168 portlets in a manner similar to the development of Web applications with Struts. PORTIONS tries to offer, combining the JSR-168 specification and the JSP Model 2 Architecture, a development framework that allows to create complex portlets.
Need to go native? The NetBeans page continues its tutorial with Beginning JNI with NetBeans C/C++ Pack 5.5, Part II . "The tutorial will take you through the creation of a sample application which uses JNI to execute some native code written in the C programming language. For the Java part of the application you will use NetBeans IDE 5.5; for the C part - NetBeans C/C++ Pack 5.5.
You will start off by creating a simple Java project, adding a native method to it and then implementing this method in C using NetBeans C/C++ Pack 5.5"
Author Elliotte Rusty Harold has joined the properties debate with his explanation of What Properties in Java Should Have Looked Like : "All the proposals are vastly too complex for what little benefit they offer. They need new keywords, operators, rules, and best practices. Could we have done better? Yes. Can we still do better? Maybe. Let's find out. The proper design of properties was invented in Eiffel over a decade ago, (or possibly some other language, but Eiffel is where I first saw it) and it's really simple and obvious. All you need are public fields."
JohnÂ O'Conner is fed up with waiting for a final Java SE 6 on the Mac and in today's Weblogs , he asks for someone to Give me any reason at all to use Mac OS X for Java development :
"I understand that consumer interest in Java apps may not be a reason to push Java SE 6 on OS X or Leopard. However, some potential customers would buy an Apple laptop or desktop system if a current JDK were available."
RichÂ Unger has been an
Itinerant Java/NetBeans speaker and this explains he recent lack of blogging:
"I've not been posting lately, but it's not for lack of excitement around here. For one thing, I've been collaborating on the forthcoming NetBeans RCP book. If you're at all interested in RCP development, I promise you this book will make your job easier."
AlexeyÂ Popov considers a Test Harness for Product-Quality Test Suites :
"This article provides some criteria that can be used when choosing a test harness for certain types of test suites. It describes requirements that are treated as most important for JT harness, the open source version of the JavaTest TM harness, and ME Framework."
In today's Forums ,
linuxhippy is looking at
Porting phoneME advanced to Nokia 770 / N800 :
"I would like to port phoneME Advanced to my Nokia770, however some questions remain open and it would be great to get some answers: * The Nokia770 has an ARM926EJ-Sid (some ARM9), the N800 a ARM11 as far as I know. Are these processors supported by the phoneME Advanced JIT? * Are there "native" X11 peers or should I use the QT peers instead? Which version of QT do you recommend? * Any hints / common pitfalls I should know about. Thank you Sun for making this possible! I couldn't believe when I found that even CDC is opensourced as GPL. Wow."
Joshua Marinacci has some advice for bleeding edge developers working with SwingX's geographic components in
Re: Again on free map providers for JXMapViewer - I hate to say this...
"That's probably the right place, but really you should be working off the new_tile_provider branch. I have refactored the TileFactory to have fewer methods and fixed a bunch of bugs. If france is near antarctica then that probably means their tiles have y=0 at the equator instead of y=0 at the top of the map. I believe there is a boolean you can pass into the TileFactoryInfo to control that."
Finally, Scott Violet updates the status of the beans binding library in
Re: Swing Binding :
"High priority does not necessarily imply a ton-o-people are working on it. [...] I plan on releasing the current prototype soon. As I said, I'm bogged down in another request to legal for usage of a different library. I hope to resolve it shortly, but legal and shortly don't often go together."
Current and upcoming Java
Registered users can submit event listings for the
href="http://www.java.net/events">java.net Events Page using our
href="http://today.java.net/cs/user/create/e">events submission form.
All submissions go through an editorial review before being posted to the
Archives and Subscriptions: This blog is delivered weekdays as
Today RSS feed . Also, once this page is no longer featured as the
front page of java.net it will be
archived along with other past issues in the
Giving your objects the functionality they need