Friday, December 11, 2009

JDebugTool 4.3.1 - Graphical Java Debugger

Hi,

I found this great debugging tool which can be used seperately, however, it is not as easy as the debugging tool in myeclipse ide but its worth using this one sometimes in spare.

http://www.debugtools.com/

Here are some of its features :


  • Standalone graphical Java debugger.

  • Built on top of the standard JPDA (Java Platform Debugger Architecture).

  • Is itself written in Java.

  • Features an intuitive and graphical Java Swing GUI.

  • Context-sensitive Help Viewer
  • Wednesday, December 9, 2009

    Ebooks for SCJP 1.6

    Hi,

    Here are some nice ebooks for people approaching for SCJP 1.6

    SCJP_SCJD_1.6_Kathy_Sierra_Bert_Bates

    Java Certified programming & developement

    Cheers!!!

    Ujjwal Soni

    Friday, November 27, 2009

    How to set a custom ToolTipManager in java flex 3.0

    I needed to set a custom implementation of the ToolTipManager (more struts for our life!!!). I was looking for solution and found it. Here it is.

    To register your own class you should invoke Singleton.registerClass(interfaceName, clazz) method with appropriate parameters. If class with interfaceName have been registered yet you cannot override it . It means you cannot register class in creationComplete, initialize or preinitialize handlers. You should create custom Preloader class and register class in constructor and set one to the application class via MXML code:


    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" preloader="CustomPreloader">
    



    Here is the example of custom preloader class:

    public class CustomPreloader extends DownloadProgressBar
       {
           public function CustomPreloader()
           {
               super();
               Singleton.registerClass("mx.managers::IToolTipManager2",
                                       CustomToolTipManager);
           }
    
       }
    



    Maybe anyone has another solution.

    Handling Page Not Found using struts

    While surfing web, Most of us have encountered 404- Page not found message. Any resource you request; If it does not exist on server you would get such an error. In struts applications when you request for x.do and if there is no Action-mapping defined in struts-config.xml file for ActionForward x; You would get such an error.

    Unknown ActionMapping

    In struts you can define one ActionMapping which will receive all requests for which no ActionMappins is defined. It is called "Unknown ActionMapping".

    name="/debug"
    unknown="true"
    forward="/pages/debug.jsp/>

    Notably one can also do some NLP or spell correction to seek for resource user might be looking for and can ask to give that resource. This helps improving user experience while surfing your site.

    Java 7 Preview

    Hi,

    Here's a PDF file which contains sneak peak preview for Java 7

    http://sites.google.com/site/ujjwalbsoni/Home/Java7Preview%5B1%5D.pdf?attredirects=0&d=1

    Java 7 is really cool...check it out !!!

    Thursday, November 26, 2009

    Problem with mozilla event mechanism

    Hi,

    Last week i was coding for a website which was totally dynamic using jsp and spring framework, I wrote many JavaScript functions to perform dynamic things throughout the website. Now, the site worked perfectly in internet explorer 8 and other old ie versions. Now my task was to make it compatible for other browsers including mozilla, opera and google chrome. I managed to make it work in opera and google chrome but failed to execute some modules in mozilla firefox !!!

    Here's where i failed

    -> document.getElementById('myid').click()

    This function failed in mozilla and worked fine in other ie versions

    I solved it using

    var oEvent = document.createEvent("MouseEvents");
    oEvent.initMouseEvent("click", true, true,window, 1, 1, 1, 1, 1, false, false, false, false, 0, target);
    target.dispatchEvent( oEvent );


    I managed to make click event dynamic using javascript functions which worked for me in both ie and mozilla


    -> Event propagation in dynamic check boxes created using DOM

    var element3 = document.createElement("input");
    cell3.setAttribute("align","center");
    element3.type = "checkbox";
    element3.id=myid;
    element3.onclick = function() { checkChangedValue('mytest',nameid, gname, e) };

    The above mechanism does not work in mozilla firefox but it works perfectly in internet explorer.

    I resolved it using

    element3.addEventListener("click", function(e) {checkChangedValue('myname',ids, gname, e);}, true);

    This works perfectly in both browsers, i had other issues with mozilla firefox but its a long list to discuss, it took around 22 hours for me to make this whole website compactible in mozilla firefox and internet explorer......Feeling like have won a war !!! One day, all browsers will follow same scripting all ower, m waiting for that day to come...

    Cheers all,

    Ujjwal

    Wednesday, November 4, 2009

    Rotated Floral Heart Bullet

    No really, it’s a Unicode character, U+2767 if you must know. I found it here (warning; won’t display properly in most browsers) via Zeldman. I made a really big picture; read on for a look.



    On my windows machine, the dingbats are noticeably absent in most fonts; only all there in, as one might guess, Zapf Dingbats.