Saturday, May 06, 2006

Java coding style

Here's the style I prefer these days.
package org.example.myproject;

import java.io.IOException;
import java.util.Map;

import org.apache.log4j.Logger;

import org.example.myproject.util.MyUtil;

/**
* This class does several things.
*
* @author name@domain.com
*/
public class MyClass {

public static final String PUB = "a";

private static final String PRIV = "b";

private String _name;

private String _description;

/**
* Construct a new MyClass.
*/
public MyClass(String name, String description) {
_name = name;
_description = description;
}

}


No comments: