Package fr.soleil.salsa.exception

Examples of fr.soleil.salsa.exception.SalsaMissingPropertyException


    public static DevicePreferences loadSystemPreferences() throws SalsaPreferencesException {
      if(devicePreferences == null){
        String scanServer = SystemUtils.getSystemProperty(SCANSERVER_PROPERTY);
          String preferencePath = SystemUtils.getSystemProperty(PREFERENCE_FILE_PROPERTY);
              if ((preferencePath == null) || preferencePath.trim().isEmpty()) {
                  throw new SalsaMissingPropertyException(PREFERENCE_FILE_PROPERTY);
              }
              else {
                devicePreferences =  load(preferencePath, scanServer);
              }
         
View Full Code Here


        catch (FileNotFoundException fnfe) {
            System.err.println("Device Preference file not found.");
            System.err.println("This file will be created (if allowed).");
            if ((devicePreferences.getScanServer() == null)
                    || (devicePreferences.getScanServer().trim().isEmpty())) {
                throw new SalsaMissingPropertyException(SCANSERVER_PROPERTY);
            }
            else {
                save(devicePreferences);
            }
        }
View Full Code Here

    public static DevicePreferences loadSystemPreferences() throws SalsaPreferencesException {
        String preferencePath = SystemUtils.getSystemProperty(PREFERENCE_FILE_PROPERTY);
        String scanServer = SystemUtils.getSystemProperty(SCANSERVER_PROPERTY);
        if ((preferencePath == null) || preferencePath.trim().isEmpty()) {
            throw new SalsaMissingPropertyException(PREFERENCE_FILE_PROPERTY);
        }
        else {
            return load(preferencePath, scanServer);
        }
    }
View Full Code Here

        catch (FileNotFoundException fnfe) {
            System.err.println("Device Preference file not found.");
            System.err.println("This file will be created (if allowed).");
            if ((devicePreferences.getScanServer() == null)
                    || (devicePreferences.getScanServer().trim().isEmpty())) {
                throw new SalsaMissingPropertyException(SCANSERVER_PROPERTY);
            }
            else {
                save(devicePreferences);
            }
        }
View Full Code Here

    public static DevicePreferences loadSystemPreferences() throws SalsaPreferencesException {
        if (devicePreferences == null) {
            String scanServer = SystemUtils.getSystemProperty(SCANSERVER_PROPERTY);
            String preferencePath = SystemUtils.getSystemProperty(PREFERENCE_FILE_PROPERTY);
            if ((preferencePath == null) || preferencePath.trim().isEmpty()) {
                throw new SalsaMissingPropertyException(PREFERENCE_FILE_PROPERTY);
            } else {
                devicePreferences = load(preferencePath, scanServer);
            }

        }
View Full Code Here

            e.printStackTrace();
        } catch (FileNotFoundException fnfe) {
            System.err.println("Device Preference file not found.");
            System.err.println("This file will be created (if allowed).");
            if ((devicePreferences.getScanServer() == null) || (devicePreferences.getScanServer().trim().isEmpty())) {
                throw new SalsaMissingPropertyException(SCANSERVER_PROPERTY);
            } else {
                save(devicePreferences);
            }
        } catch (IOException e) {
            System.err.println("Unable to load device preference file.");
View Full Code Here

    public static String PREFERENCE_FILE_PROPERTY = "SALSA_UI_PREFERENCES";

    protected static void loadSystemPreferences() throws SalsaPreferencesException {
        String preferencePath = SystemUtils.getSystemProperty(PREFERENCE_FILE_PROPERTY);
        if ((preferencePath == null) || preferencePath.trim().isEmpty()) {
            throw new SalsaMissingPropertyException(PREFERENCE_FILE_PROPERTY);
        } else {
            load(preferencePath);
        }
    }
View Full Code Here

    public static String PREFERENCE_FILE_PROPERTY = "SALSA_UI_PREFERENCES";

    public static UIPreferences loadSystemPreferences() throws SalsaPreferencesException {
        String preferencePath = SystemUtils.getSystemProperty(PREFERENCE_FILE_PROPERTY);
        if ((preferencePath == null) || preferencePath.trim().isEmpty()) {
            throw new SalsaMissingPropertyException(PREFERENCE_FILE_PROPERTY);
        }
        else {
            return load(preferencePath);
        }
    }
View Full Code Here

        }

        salsaResult.setBatch(salsaExecute);

        if (tangoHost == null || tangoHost.trim().isEmpty()) {
            printCorrectUsageAndExit(new SalsaMissingPropertyException("TANGO_HOST"));
        } else if (serverUrl == null || serverUrl.trim().isEmpty()) {
            printCorrectUsageAndExit(new SalsaMissingPropertyException("SALSA_SERVER_URL"));
        } else if (login == null || login.trim().isEmpty()) {
            printCorrectUsageAndExit(new SalsaMissingPropertyException("SALSA_LOGIN"));
        } else {
            // Launch SalsaTrajectoryBean with specified config
            if (roMode) {
                splash.setMessage("Build Salsa read only panel");
                splash.progress(40);
View Full Code Here

        if (devicePreferences == null) {
            String scanServer = SystemUtils.getSystemProperty(SCANSERVER_PROPERTY);
            String preferencePath = SystemUtils.getSystemProperty(PREFERENCE_FILE_PROPERTY);
            if ((preferencePath == null) || preferencePath.trim().isEmpty()) {
                LOGGER.error("Missing property " + PREFERENCE_FILE_PROPERTY);
                throw new SalsaMissingPropertyException(PREFERENCE_FILE_PROPERTY);
            } else {
                devicePreferences = load(preferencePath, scanServer);
            }

        }
View Full Code Here

TOP

Related Classes of fr.soleil.salsa.exception.SalsaMissingPropertyException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.