FileDocCategorySizeDatePackage
ClassCast.javaAPI DocExample749Sun Feb 22 20:30:32 GMT 2004None

ClassCast

public class ClassCast extends Object
Class Casting Demo.

Fields Summary
Constructors Summary
Methods Summary
public static voidmain(java.lang.String[] argv)


		CCA anA = new CCA();
		CCB aB = new CCB(1);
		CCC aC = new CCC(2,3);

		System.out.println("A = " + anA);
		System.out.println("B = " + aB);
		System.out.println("C = " + aC);

		CCA aCast = aC;
		System.out.println("aCast = " + aCast);

		CCC anotherC = (CCC) aCast;
		System.out.println("anotherC = " + anotherC);