Some fix-ups for java conventions posted

Discussion in 'Programming General' started by xk1llxk1llx, Jul 29, 2010.

Some fix-ups for java conventions posted
  1. Unread #1 - Jul 29, 2010 at 2:56 PM
  2. xk1llxk1llx
    Joined:
    Apr 13, 2008
    Posts:
    212
    Referrals:
    2
    Sythe Gold:
    0
    Tier 1 Prizebox

    xk1llxk1llx awesomeness lurks within this playa ;)
    $100 USD Donor New

    Some fix-ups for java conventions posted

    Follow this guide link: http://www.sythe.org/showthread.php?t=704103

    This is needed, he messed up on some stuff.

    This is straight from JAVA conventions:

    for catch and try blocks it should be like this:
    Code:
        try {
                 code;
        catch(IOException e)
             System.out.println("Error dectected line XXXX.");
        
    Thats how it is suppose to be
    1 tab space down from the code for try
    same space as try for catch
    7 spaces for error printed in CMD.

    also this is NOT from java conventions, they didn't explain it well and made code still look messy.
    for declarations he messed up this is how I do it and how it SHOULD be

    Code:
        int awesome;
        private int[] sharks = { 13099, 19329, 3999 };
        boolean sharksareawesome;
    
    as you see, if you are only using the declarations inside the class ONLY.
    put private.

    and there should be 4 spaces then declared, or else code looks messy.

    Thanks,
    Xk1llXk1llX
     
< Web Crawler - Help! | Shape Your Enterprise for New Business Realities >

Users viewing this thread
1 guest


 
 
Adblock breaks this site