KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > NullExample


1 public class NullExample
2 {
3     int foo(Object JavaDoc o, String JavaDoc p)
4     {
5         if (o == null)
6         {
7             return 2;
8         }
9         int i = 2;
10         i += p.length();
11         System.out.println(p);
12         return 4;
13     }
14 }
15
Popular Tags