submited by krishnas on Thu Mar 27th, 2008
java
I needn’t emphasize the importance of choosing best name for class/variable/method. But how many managers/developers care in choosing best names. Most of them concentrate on completing assigned task and deliver working output, because they feel that naming is not going to add any value to their software....
more »
submited by krishnas on Thu Mar 27th, 2008
spring google-guice
Guice is alternative to Spring framework except life cycle management.
I like Guice framework over Spring for the following reason....
more »
submited by krishnas on Thu Mar 27th, 2008
java
ArrayList and HashMap are a few of the most frequently used data structures in Java development. So I would like to talk about the importance of instantiating these classes with initial capacity. Let me explain how the ArrayList works internally, so that you get a good insight. HashMap works almost the same way an ArrayList works, so I haven’t covered the details of that separately. But all the tips given below are applicable for HashMap as well....
more »
submited by krishnas on Thu Mar 27th, 2008
spring jsf struts
Recently I got an opportunity to explore Spring Web FlowExternal Link framework. Later I came to know that Shale DialogExternal Link also solves the same problem. JBoss Seam too solves the same problem....
more »
submited by krishnas on Thu Mar 27th, 2008
java
During my Java training, I read about volatile keyword, but didn’t get clear understanding. Recently when I wrote a singleton class using double checked locking, PMD code reviewer gave a warning not to use volatile. Later I started exploring on double checked locking issue, here is my observation....
more »
submited by krishnas on Thu Mar 27th, 2008
java
This is one of the frequently asked questions in the interview. Most of the interviewer expect the below answer.
“Thread.stop() method is deprecated, so a boolean variable has to be introduced in thread class and run method should check the boolean variable whether to continue execution or come out of run() method”....
more »
submited by krishnas on Thu Mar 27th, 2008
java
Singleton is one of the frequently used and easily understandable design pattern. Most of the tutorials and books give example of making the constructor as private and exposing a static method which will provide single instance. The common example they use is Runtime class of JRE....
more »
submited by krishnas on Thu Mar 27th, 2008
seam
The preview chapters will soon be released but you can get a sneak peak by accessing the code examples here. Feel free to download the examples and try them out! Each example project included in the source bundle is a variant of the Seam Hotel Booking example. The booking project demonstrates the use of natural conversations and navigation-based conversation management while the nestedbooking project demonstrates the use of nested conversations....
more »
submited by krishnas on Thu Mar 27th, 2008
seam jsf
JBoss 4.2.1.GA comes with JSF 1.2 RI (Reference Implementation) and by default registers JBossJSFConfigureListener class as a context listener for any web app you deploy. To see how this is done, look at the web.xml file under
\ server\ default\ deploy\ jboss-web.deployer\ conf\ directory. The above web.xml is common to all web applications you deploy which means that JBossJSFConfigureListener gets a chance to participate in your web application lifecycle events, such as when the context is initialized and when the context is destroyed....
more »
submited by krishnas on Thu Mar 27th, 2008
seam
The much anticipated Second Edition of JBoss(R) Seam: Simplicity and Power Beyond Java(TM) EE (Prentice Hall JBoss) is coming soon. Michael Yuan and myself have teamed up to develop the content for the upcoming Second Edition which will cover the ins and outs of Seam 2, and I don’t just mean bijection...
more »