Monday, April 27, 2009

5 Golden Rules of widening, boxing & varargs

Rules :
1. Primitive Widening > Boxing > Varargs.
2. Widening and Boxing (WB) not allowed.
3. Boxing and Widening (BW) allowed.
4. While overloading, Widening + vararg and Boxing + vararg can only be used in a mutually exclusive manner i.e. not together.
5. Widening between wrapper classes not allowed


No comments:

Post a Comment

Thank you for your feedback