import java.io.* ; public class Client { public static void main( String[] args ) { // Initialize the ORB. org.omg.CORBA.ORB orb = org.omg.CORBA.ORB.init( args, null ); String ref = null; try { BufferedReader in = new BufferedReader( new FileReader( "./account.objid" )); ref = in.readLine(); } catch( IOException ex ) { System.out.println( "Could not open file 'account.ref'" ); System.exit( -1 ); } org.omg.CORBA.Object obj = orb.string_to_object( ref ); Account account = AccountHelper.narrow( obj ); account.deposit( 700 ); account.withdraw( 700 ); account.deposit( 700 ); account.withdraw( 700 ); account.deposit( 700 ); account.withdraw( 700 ); account.deposit( 700 ); account.withdraw( 700 ); account.deposit( 700 ); account.withdraw( 250 ); System.out.println("The balance is " + account.balance() ); } }