KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > invoice > Builder


1 package invoice;
2
3 import java.io.IOException JavaDoc;
4
5
6 /**
7  * @author S.Chassande-Barrioz
8  */

9 public class Builder {
10
11     public static void main(String JavaDoc[] args) {
12         InvoiceAppsHelper a = null;
13         try {
14             a = new InvoiceAppsHelper(args[0]);
15         } catch (IOException JavaDoc e) {
16             e.printStackTrace();
17             System.exit(-1);
18         }
19         System.out.println("Creating the addresses...");
20         a.createAdresses();
21
22         System.out.println("Creating the products...");
23         a.createProducts();
24
25         System.out.println("Creating the invoice...");
26         Invoice i = a.createInvoice();
27
28         System.out.println("Data base:");
29         System.out.println("==========");
30         a.printAll();
31     }
32 }
33
Popular Tags