View Javadoc

1   /*
2    * $Id: LoanBrokerApp.java 11394 2008-03-17 15:18:29Z tcarlson $
3    * --------------------------------------------------------------------------------------
4    * Copyright (c) MuleSource, Inc.  All rights reserved.  http://www.mulesource.com
5    *
6    * The software in this package is published under the terms of the CPAL v1.0
7    * license, a copy of which has been included with this distribution in the
8    * LICENSE.txt file.
9    */
10  
11  package org.mule.example.loanbroker.bpm;
12  
13  import org.mule.example.loanbroker.AbstractLoanBrokerApp;
14  import org.mule.transport.jdbc.util.MuleDerbyUtils;
15  
16  /**
17   * Executes the LoanBroker BPM example.
18   */
19  public class LoanBrokerApp extends AbstractLoanBrokerApp
20  {
21      public LoanBrokerApp(String config) throws Exception
22      {
23          super(config);
24      }
25  
26      public static void main(String[] args) throws Exception
27      {
28          LoanBrokerApp loanBrokerApp = new LoanBrokerApp("loan-broker-bpm-mule-config.xml");
29          loanBrokerApp.run(false);
30      }
31  
32      @Override
33      protected void init() throws Exception
34      {
35          // before initialisation occurs, the database must be cleaned and a new one created
36          MuleDerbyUtils.defaultDerbyCleanAndInit("derby.properties", "database.name");
37          super.init();
38      }
39  }