//
// PayableTest.java
// Test class for the Payable interface
//
// Nadeem Abdul Hamid (based on Deitel & Deitel, Java How To Program)
// CSC 121 - Berry College
//

public class PayableTest {

    public static void main( String args[] ) {
        Payable payObjs[] = new Payable[ 4 ];

        payObjs[ 0 ] = new Invoice( "01234", "seat", 2, 375.00 );
        payObjs[ 1 ] = new Invoice( "56789", "tire", 4, 79.95 );
        payObjs[ 2 ] = 
            new SalariedEmployee2( "Lisa Barnes", "222-22-2222", 1200.00 );
        payObjs[ 3 ] = 
            new SalariedEmployee2( "John Smith", "111-11-1111", 800.00 );

        System.out.println( "\nInvoices and Employees processed polymorphically:\n" );

        for ( int i = 0; i < payObjs.length; i++ ) {
            System.out.println( payObjs[ i ].toString() +
                                          "\npayment due: " + payObjs[ i ].getPaymentAmount() +
                                          "\n\n");
        } // end for
    } // end method main

} // end class PayableTest