Archive for category Java
Sun Java to be 100% open source
Posted by Alexey in Java, News, Software Development on Ноябрь 14, 2006
Finally, Sun relicenses Java under GPL. AFAIK JVM native sources were open (but not under OS certified licence) for quite a while already, but now Sun implementation of JSE is going to be true open source. Great news — long awaited!
Sun Certified Business Component Developer
Posted by Alexey in Java, Occurrences, Software Development on Июнь 22, 2006
I’ve passed the «Sun Certified Business Component Developer for J2EE 1.3″ today. With amazingly high score of 95% (67 of 70 questions answered correctly). I’m saying amazingly because I did not really expect that. My knowledge of EJB 2.0 faded since I last worked with it (back in 2004). What I did to prepare is I used questions downloaded from ExamCollection.com — 88 questions in total. The quality of answers was rather poor, I found at least 10 incorrect answers, but nevertheless they helped me to identify my weak areas. Then I just briefly scanned these areas in the EJB spec and the preparation was over. Took me four sessions by 1-2 hours each to prepare.
My weakest areas appeared to be:
- Session bean lifecycle — 66% corect answers, 2 questions answered incorrectly
- Transactions — 87% correct answers, 1 question answered incorrectly
All other areas (about 10 more) are topped at 100%.
This time I chose prometric certified test center in Luton (last time it was Wembley). I liked it better: bigger classroom (lit better too) and no problems with parking which is also much cheaper, £1.50 instead of £8 in Wembley.
So… here I am, another certificate at hand, congratulations are gladly accepted!
Misspellings
Real life mis-spellings (saw them during last two days):
- MDB = Massage Driven Bean (sorry this one is Java specific)
- … CMMI curses are available … (from a corporate email)
Java community responds
Java community oficially responded to my post Three years apart with their triple salute:
Interestingly, some of them were drinking russian Baltika!
Look, instance initialiser!
Posted by Alexey in Java, Software Development on Май 8, 2006
Another thing that I would have learnt had a read a Java Language Specification:
There are instance inistialisers in Java
Discovered May 2006
In java, a class can have an instance initialiser, which is executed before constructor is called. I knew about static initialisers that are called when the class is loaded, but never heard about instance initialisers. A colleague taught me that
class Foo { private int i; {i = 5;} //instance initialiser }
It is sometimes useful in anonymous classes as they cannot have a constructor.
Added to Things that I still discover about Java.
On usability of Java 5 language features
Posted by Alexey in Java, Software Development on Март 12, 2006
I only had a chance to develop using JDK5 for a short period of 1 month. And it was 1.5 years ago. Recently I needed a quick solution for basically a script comparing two Excel spreadsheets for matching records and recording results into same spreadsheets. Since I programmed in Java really fast and I felt reluctant indeed to get myself buried into MS VB for Excel documentation, and also taking into account my good experience with Jakarta POI — a Java API To Access Microsoft Format Files, I decided in favour of Java. (Well those were mostly excuses as you might have guessed anyway
).
& operator is applicable to booleans
While I thought binary operator & in Java was designed to work with integer types, it appeared to be perfectly applicable to boolean operands and worked exactly the same way as &&:
//always true: assertTrue(boolean1 & boolean2 == boolean1 && boolean2);
See more things that I still discover about Java.
Quake 2 written in java
Guys from Bytonic have created a java port of open-sourced quake2 engine. It is using standard Java3D API and two different implementations of Java3D based on OpenGL. So apart from OpenGL the engine is all pure java. Although they have a benchmark page, I was interested to test it myself. So I downloaded jake2 (this is how the port is called) and original q2 demo version. I used q2demo1.dm2 to measure fps. I left all the settings at their default values except the resolution which I set to 1024×768, full screen. jake2 showed 212 fps, original C version resulted in 191 fps. The only thing that was unfair is that jake2 was based on quake2 3.21 sources and original demo I used was version 3.14.
I had a glance at the java sources too. Naturally, they don’t look like proper java sources but more like not very object oriented C sources. At the end of the day, this is a port from conceptually different language, not an original application.
The conclusion is whoever challenges the performance of modern JVMs is welcome to give jake2 a try and eat dirt
void.class
Posted by Alexey in Java, Software Development on Ноябрь 22, 2005
Ha, another addition to my Things that I still discover about Java registry: Expression void.class is legitimate and results in a java.lang.Class instance representing void type. I did know that each primitive type had its own Class referenced as byte.class or char.class, but had no clue that you could do same thing with void.
IntelliJ IDEA 6 will have Websphere support!
Posted by Alexey in Java, Software Development on Ноябрь 21, 2005
Yow! According to «IntelliJ 6.0 (Demetra) Roadmap released» TSS article, next major version of my favourite and truly enjoyable Java IDE, IntelliJ IDEA will have support for IBM Websphere appserver. That would be a pleasant addition for me. Currently, I use a somewhat hacker’s approach to start/stop Webshpere instances on my computer. I intercepted the command line that WSAD (IBM’s IDE) is using to start integrated Websphere, and now use it to start Websphere from ant script. The major drawback is that sometimes server state needs synchronisation with the config files, which only can be done from WSAD. Also, re-generating deployment sources requires WSAD too. Although I am not sure these will be addressed in IDEA 6.0, it is a good step forward for such a great IDE.


Свежие комментарии