daily pastebin goal
2%
SHARE
TWEET

Untitled

a guest Jun 13th, 2018 53 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. public class InvoiceTest {
  2.  
  3.     public static void main(String[] args)
  4.     {
  5.         Invoice invoice = new Invoice("0001", "A random part", 6, 3.00);
  6.        
  7.         System.out.printf("Part number is: %s\n", invoice.getPartNumber());
  8.         System.out.printf("Part description is: %s\n", invoice.getPartDescription());
  9.         System.out.printf("Part quantity is: %d\n", invoice.getPartQuantity());
  10.         System.out.printf("Part price is: %.2f\n", invoice.getPartPrice());
  11.         System.out.printf("Invoice price is: %.2f\n", invoice.getInvoiceAmount());
  12.  
  13.         System.out.println("\n");
  14.        
  15.         invoice.setPartNumber("0002");
  16.         invoice.setPartDescription("A different part");
  17.         invoice.setPartQuantity(2);
  18.         invoice.setPartPrice(4.00);
  19.        
  20.         System.out.printf("Part number is: %s\n", invoice.getPartNumber());
  21.         System.out.printf("Part description is: %s\n", invoice.getPartDescription());
  22.         System.out.printf("Part quantity is: %d\n", invoice.getPartQuantity());
  23.         System.out.printf("Part price is: %.2f\n", invoice.getPartPrice());
  24.         System.out.printf("Invoice price is: %.2f\n", invoice.getInvoiceAmount());
  25.     }//end of main
  26.    
  27. }
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top