In eclipse, when you hit F3 while your cursor is over some code in .java file, it will jump to its declaration. It's all good except in the case of an interface. For a method in interface, most of time you want to see its implementation not its declaration. There are few ways to work around this:
- Ctrl+mouse over the text will show options to jump to declaration or implementation.
- Ctrl+t will also show you options for both interface and its implementation.
First one requires me to use mouse, second one is not intuitive because I am used to hitting F3 to do similar operation. Ideally, you would like to see some combination of F3 doing its job. The Implementors plugin does exactly that. Now when I hit, ALT+F3 it goes directly to its implementation.
An effort to rationalize events happening around us - mostly software engineering !!
Thursday, August 19, 2010
Friday, August 6, 2010
Some new kind of entertainment for your portal
Most of us like and love movies and we have some favourite stars and sometimes we even hang their posters. Even folks at prison get to do that; remember Rita Hayworth in Shaswshank Redemption. Now if you don't know who Rita Hayworth is and which movie I am talking about, you would probably google it and your search would more likely take you to IMDB or Wikipedia - yaaaawn ;-) Now imagine not having to do that and getting those information in your own portal. YE !!
Introducing Netflix portlet. Since picutures are worth thousand words, here are some screenshots with details of Shawshank Redemption. For a movie and TV series, the portlet currently shows its synopsis, cast, ratings, awards, poster if available.

For an actor, it shows his/her biography, filmography and of course a picture if available. Here is a screen shot of portlet with details of one of the actors I like.

Now some interesting details: Portlet consumes data using Netflix's webservices API hence to have this portlet running on your server you need to have proper key which you can get from Neflix's Dev page and when you start your server, you simply add
Disclaimer: This portlet is not officially supported by JBoss, by Redhat.
Help support my mission: http://www.eejot.org
Introducing Netflix portlet. Since picutures are worth thousand words, here are some screenshots with details of Shawshank Redemption. For a movie and TV series, the portlet currently shows its synopsis, cast, ratings, awards, poster if available.

For an actor, it shows his/her biography, filmography and of course a picture if available. Here is a screen shot of portlet with details of one of the actors I like.

Now some interesting details: Portlet consumes data using Netflix's webservices API hence to have this portlet running on your server you need to have proper key which you can get from Neflix's Dev page and when you start your server, you simply add
-Dnetflix.consumer.key=blah -Dnetflix.consumer.secret=blahblah
as JVM parameters. Portlet is based on JBoss Richfaces 3.3.3.Final, JBoss PortletBridge 2.0.0.Final and has been tested with GateIn Portal and JBoss Enteprise Portal Platform 5. The source code of this portlet can be downloaded from http://anonsvn.jboss.org/repos/qa/prabhat/netflixDisclaimer: This portlet is not officially supported by JBoss, by Redhat.
Help support my mission: http://www.eejot.org
Friday, June 25, 2010
Richfaces Presentation at Austin JUG
I will be giving a 45-min presentation on JBoss Richfaces at Austin JUG on June 29 starting at 7 PM. More details at http://austinjug.org/index.jsp?p=events-20100629 I hope to see you there if you are in town.
Friday, April 23, 2010
Java's Language discrimination against Nepali
I will let following code and it's output do the talking:
Here is the output:
Just for curious mind, this came up when I was trying to see why Nepali is not written as नेपाली in "Change Language" dialog box in GateIn.
System.out.println ("Korean testing: ");
Locale locale = new Locale("ko");
System.out.println("DisplayName in current locale:" + locale.getDisplayLanguage());
System.out.println("Display Name in Native: " + locale.getDisplayLanguage(locale));
System.out.println ("\n French testing: ");
locale = new Locale("fr");
System.out.println("DisplayName in current locale:" + locale.getDisplayLanguage());
System.out.println("Display Name in Native: " + locale.getDisplayLanguage(locale));
System.out.println ("\n Hindi testing: ");
locale = new Locale("hi");
System.out.println("DisplayName in current locale:" + locale.getDisplayLanguage());
System.out.println("Display Name in Native: " + locale.getDisplayLanguage(locale));
System.out.println ("\n Nepali testing: ");
locale = new Locale("ne");
System.out.println("DisplayName in current locale:" + locale.getDisplayLanguage());
System.out.println("Display Name in Native: " + locale.getDisplayLanguage(locale));
Here is the output:
Korean testing:What the heck?? I understand that Nepali is not as widely spoken as other languages that are shown above but given that you can show Hindi in "Devnagiri script" and Nepali also shares the same script, why would Java not apply that to Nepali as well? Do I smell discrimination here? ;-)
DisplayName in current locale:Korean
Display Name in Native: 한국어
French testing:
DisplayName in current locale:French
Display Name in Native: français
Hindi testing:
DisplayName in current locale:Hindi
Display Name in Native: हिंदी
Nepali testing:
DisplayName in current locale:Nepali
Display Name in Native: Nepali
Just for curious mind, this came up when I was trying to see why Nepali is not written as नेपाली in "Change Language" dialog box in GateIn.
Monday, April 12, 2010
Tips when adding extra memory to your laptop
I recently got a new Lenovo T500 that had 2G RAM into it. I installed 32-bit Fedora 12 on it which worked flawlessly, even dual monitor. Then I got an extra 2G RAM which meant that I needed to open laptop case to install it. It gave me some jitters given that I have not unscrewed any laptop before. The last time I did something close to this was way back in 2000 when I put extra hard disk into my Dell Desktop to have dual boot with Windows ME and Red Hat Linux 6. Fedora was not born then.
I followed T500 hardware maintenance manual at http://download.lenovo.com/ibmdl/pub/pc/pccbbs/mobiles_pdf/43y6630_04.pdf, rushed to Radioshack to get screw driver for 14 mm screws and with some fiddling, snapped the thing in its slot. Reboot and
[prabhat@eejot ~]$ more /proc/meminfo
MemTotal: 3057360 kB
MemFree: 2192648 kB
Buffers: 45864 kB
What? Should not MemTotal be somewhere close to 4194304 kB? Then I come to know about PAE, did a 'sudo yum install kernel-PAE', reboot and Voila. Now I see
[prabhat@eejot ~]$ more /proc/meminfo
MemTotal: 4013920 kB
MemFree: 2397700 kB
which looks much better. Thanks Matt for pointers. :-)
I followed T500 hardware maintenance manual at http://download.lenovo.com/ibmdl/pub/pc/pccbbs/mobiles_pdf/43y6630_04.pdf, rushed to Radioshack to get screw driver for 14 mm screws and with some fiddling, snapped the thing in its slot. Reboot and
[prabhat@eejot ~]$ more /proc/meminfo
MemTotal: 3057360 kB
MemFree: 2192648 kB
Buffers: 45864 kB
What? Should not MemTotal be somewhere close to 4194304 kB? Then I come to know about PAE, did a 'sudo yum install kernel-PAE', reboot and Voila. Now I see
[prabhat@eejot ~]$ more /proc/meminfo
MemTotal: 4013920 kB
MemFree: 2397700 kB
which looks much better. Thanks Matt for pointers. :-)
Thursday, April 1, 2010
Saga of Lawn Mowers
My wife and I bought a house in November last year. We are slowly getting used to all chores that come with buying a house. Since we bought it towards the beginning of winter, I did not have to worry about mowing my lawn. Now that winter is already over and Texas summer has already announced its arrival, I need to start taking out weeds, mowing our lawn and watering it.
For mower, I tweeted and facebooked asking opinions of my friends. Not surprisingly, I got good feedbacks with both gas and electric motor getting equal and majority of votes and couple going for reel mower which I did not even know that it existed. A reel mower does not have an engine and it's run by your sweat and blood and that sounded promising to me. I finally got one on last Monday from Lowe's and it looks like it does its job well. Assembly required about 20 mins. I have 30 days to return it which means it has to pass my tests at least two more times and I hope that it lasts longer. Now let's come to the main point:
For mower, I tweeted and facebooked asking opinions of my friends. Not surprisingly, I got good feedbacks with both gas and electric motor getting equal and majority of votes and couple going for reel mower which I did not even know that it existed. A reel mower does not have an engine and it's run by your sweat and blood and that sounded promising to me. I finally got one on last Monday from Lowe's and it looks like it does its job well. Assembly required about 20 mins. I have 30 days to return it which means it has to pass my tests at least two more times and I hope that it lasts longer. Now let's come to the main point:
- Having a gym membership and not been there for past 6 months -> Waste of Money
- Buying a reel mower for $100 and cancelling gym membership -> Sweet and you do the math.
- Buying a reel mower and enjoying the outdoor -> Very sweet
- Buying a reel mower and doing tiny bits to help the environment -> Priceless
Wednesday, March 10, 2010
What? You can tictactoe in GateIn Portal?
If you thought Portal was only about serious stuffs such as content aggregation, integration of different applications, out of box personalization and natural front end to SOA etc then think again. Using GateIn's gadgets, you already could import different cool gadgets say from Google to your dashboard and page. Now you can tic-tac-toe as well. Here is a screen shot from GateIn Portal for you i-dont-believe-until-i-see kinds.

And if you are i-want-to-checkout-code-and-try kind, you can do so from http://anonsvn.jboss.org/repos/qa/prabhat/tictactoe-portlet/ . It's tested with Richfaces 3.3.-SNAPSHOT, JBoss PortletBridge 2.0.0.CR1 and the latest and greatest GateIn Portal. By the way, this portlet works flawlessly on JBoss Portal 2.7 and Enterprise Portal Platform 4.3 as well.
If you have been following my blog, then last week I blogged about few Richfaces examples that my team members wrote. . It took a while to port tic-tac-toe to GateIn running with JBoss AS 5 because I ran into this nasty bug https://jira.jboss.org/jira/browse/RF-8436 which has been fixed in Richface 3.3.3-SNAPSHOT and should be available in upcoming 3.3.3.GA release. Please watch this space for more cool portlets that are on the way.
--------------
Visit www.eejot.org and help me raise some funds.

And if you are i-want-to-checkout-code-and-try kind, you can do so from http://anonsvn.jboss.org/repos/qa/prabhat/tictactoe-portlet/ . It's tested with Richfaces 3.3.-SNAPSHOT, JBoss PortletBridge 2.0.0.CR1 and the latest and greatest GateIn Portal. By the way, this portlet works flawlessly on JBoss Portal 2.7 and Enterprise Portal Platform 4.3 as well.
If you have been following my blog, then last week I blogged about few Richfaces examples that my team members wrote. . It took a while to port tic-tac-toe to GateIn running with JBoss AS 5 because I ran into this nasty bug https://jira.jboss.org/jira/browse/RF-8436 which has been fixed in Richface 3.3.3-SNAPSHOT and should be available in upcoming 3.3.3.GA release. Please watch this space for more cool portlets that are on the way.
--------------
Visit www.eejot.org and help me raise some funds.
Subscribe to:
Posts (Atom)