Package fr.soleil.salsa.entity

Examples of fr.soleil.salsa.entity.IConfig


    }

    @Override
    public void setData(double arg0) {

        IConfig config = applicationController.getConfig();
        if (config == null) {
            return;
        }
        if (config.getType() == ScanType.SCAN_HCS) {
            return;
        }
        else {
            List<ISensor> sensorsList = scanResult.getSensorsList();
            List<IActuator> actuatorsXList = scanResult.getActuatorsXList();
View Full Code Here


            return null;
        }
        List<IConfig> configs = parent.getConfigList();

        for (int i = 0; i < configs.size(); i++) {
            IConfig c = configs.get(i);
            if (c.getName().equals(configName)) {
                return c;
            }
        }
        return null;
    }
View Full Code Here

    private IConfig findConfig(IDirectory root, List<String> path, String configName)
            throws ScanNotFoundException {

        IDirectory parent = findDirectory(root, path);
        if (parent != null) {
            IConfig c = findConfig(parent, configName);
            if (c != null) {
                return c;
            }
        }
        throw new ScanNotFoundException();
View Full Code Here

        String[] path = fullPath.split("/");
        List<String> pathList = new ArrayList<String>();
        pathList.addAll(Arrays.asList(path));

        String configName = pathList.remove(pathList.size() - 1);
        IConfig c = findConfig(root, pathList, configName);
        if (c != null) {
            int configId = c.getId();
            c = getConfigById(configId);
        }
        return c;
    }
View Full Code Here

    }

    @Override
    public IConfig loadConfigByPath(String path) {

        IConfig config;

        try {
            config = getConfigByPath(path);
        }
        catch (ScanNotFoundException e) {
View Full Code Here

public class ConfigAPIClient {

    public static IConfig getConfigById(Integer id) {

        IConfig resultImpl = ConfigApi.getConfigById(id);
        IConfig resultModel = AutoCopier.copy(resultImpl);
        return resultModel;

    }
View Full Code Here

        return resultModel;

    }

    public static IConfig saveConfig(IConfig config) throws PersistenceException {
        IConfig configImpl = AutoCopier.copyToImpl(config);
        IConfig resultImpl = ConfigApi.saveConfig(configImpl);
        IConfig resultModel = AutoCopier.copy(resultImpl);
        return resultModel;
    }
View Full Code Here

     *
     * @param path of the scan.
     * @throws PersistenceException
     */
    public static IConfig loadConfigByPath(String path) throws PersistenceException {
        IConfig config = configService.loadConfigByPath(path);
        return config;
    }
View Full Code Here

     *
     * @param id of the scan.
     * @throws PersistenceException
     */
    public static IConfig loadConfigById(Integer id) throws PersistenceException {
        IConfig config = configService.loadConfigById(id);
        return config;
    }
View Full Code Here

     */
    @Override
    public void notifyConfigSelected(ConfigTreeNode configTreeNode) {
        ConfigChangeListener.getInstance().stopListening();
        if (configTreeNode != null) {
            IConfig selectedConfig = configTreeNode.getConfig();
            Integer configId = selectedConfig.getId();
            if (configId != null && !selectedConfig.isLoaded()) {
                IConfig newConfig = loadConfig(selectedConfig);
                configTreeNode.setConfig(newConfig);
                currentConfig = newConfig;
                applicationController.setConfig(newConfig);
                updatWindowMenu(newConfig);
            }
View Full Code Here

TOP

Related Classes of fr.soleil.salsa.entity.IConfig

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.