Delete saved SVN stored password from eclipse

May 25, 2011 by Sandeep Bhardwaj | Tags:

If you wanted to delete the stored subversion (svn) password from Eclipse IDE. Then follow these steps :- SVN stores the authentication in physical files. The easiest way is to delete those files physically from the directory. On windows XP, these files are located in the following two folders...

Read more

Comparing two list and removing duplicate elements

March 08, 2011 by Sandeep Bhardwaj | Tags:

Comparing two list and removing duplicate elements. import java.util.ArrayList; import java.util.List; public class CheckList { public static void main(String[] args) { List<string> a = new ArrayList<string>(); a.add("a"); a.add("b"); List<string> b = new ArrayLis...

Read more

Common BeanUtils to set html form values in Java Bean

March 08, 2011 by Sandeep Bhardwaj | Tags:

Hi All, Today I am going to discuss about a important jar commons-beanutils used by struts framework and demonstrating how to use this important jar in our servlet and jsp project. If you worked with struts1 or struts2 then you noticed that the ActionForm or Action (in Struts2) linked with your ...

Read more

Enum in java

March 04, 2011 by Sandeep Bhardwaj | Tags:

Enum: Get value using enum enum Day { SUNDAY(1), MONDAY(2), TUESDAY(3), WEDNESDAY(4), THURSDAY(5), FRIDAY(6), SATURDAY(7); private final int dayCode; private Day(int dayCode) { this.dayCode = dayCode; } public int getCode() { return dayCode; } } pu...

Read more

Varargs:- Variable argument method in Java 5

February 16, 2011 by Sandeep Bhardwaj | Tags:

Varargs enables to write methods which can takes variable length of arguments.Varargs was added in Java 5 and the syntax includes three dots … provides the functionality to pass any number of arguments to a method. Syntax public void showDepartmentEmp(int deptCode, String... deptEmp){} Exampl...

Read more