public static void main(String[] args) {
        if (args == null || args.length == 0) {
            System.out.println(" Missing Settings File Argument!");
            System.exit(-1);
        }
        File settingsFile = new File(args[0]);
        if (!settingsFile.isFile()) {
            System.out.println("Settings file " + settingsFile.getPath() + " is not found! Please run configuration wizzard first");
            System.exit(-1);
        }
        DBSettings settings = loadSettings(settingsFile);
        ConfigurationReader reader = new ConfigurationReader();
        if (settings.get(DBSettings.POS_SSLENABLED).equals("1")) {
            initSSL(settings);
        }
        try {
            SessionSettings sessionSettings = reader.read(settings);
            if (!new File(Constants.LOCALDB_name).exists()) {
                System.out.println("Creating local database. Please wait...");
                if (LocalDatabaseManager.create(settings.get(DBSettings.POS_TABLEPREFIX))) {
                    System.out.println("Local database created");
                }
            }
            POSGUI theGUI = new POSGUI();
            AuthenticateService authService = new AuthenticateServiceImpl(sessionSettings);
            final DaoFactory daoFactory = new DaoFactory();
            PointOfSaleSystemImpl saleSystem = new PointOfSaleSystemImpl(authService, daoFactory);
            StudentInformationDAO studentInformationDAO = createSISDao(daoFactory);
            StudentInformationSystem studentSystem = new StudentInformationSystemImpl(sessionSettings.getSisSettings(),
                    studentInformationDAO, createOfficerSISDao(daoFactory));
            POSController cont = new POSController(theGUI, sessionSettings, saleSystem, studentSystem);

        } catch (ConfigurationException e) {
            System.out.println("Configuration error: " + e.getMessage());
            System.out.println("System Halted, please set debug to 1 in the settings file to debug the problem.");
        }
    }