Examples of IHook


Examples of fr.soleil.salsa.entity.IHook

            list.remove(index);
        }
    }

    public void notifyCommandSelected(int hookId, int commandId, boolean selected) {
        IHook h = hooks.get(hookId);
        if (h.getCommandsList() != null && h.getCommandsList().size() > commandId) {
            IHookCommand c = h.getCommandsList().get(commandId);

            if (selected) {
                commandsSelected.add(c);
            }
            else {
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

                if (hookList == null) {
                    hookList = new ArrayList<IHook>();
                    scanAddOns.setHooks(hookList);
                }
                if (hookList != null) {
                    IHook hook = null;
                    for (IHook ahook : hookList) {
                        if (ahook.getStage() == stage) {
                            hook = ahook;
                        }
                    }
                    if (hook == null) {
                        hook = new HookModel();
                        hook.setStage(stage);
                        hookList.add(hook);
                    }

                    hook.setCommandsList(commandList);
                }
                config.setScanAddOn(scanAddOns);
            }
            config.setModified(true);
        }
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

        return stageReserved;
    }

    @Override
    public void notifyDeleteCommandAction(int id, List<Integer> commandToDel) {
        IHook h = hooks.get(id);
        List<IHookCommand> commandsList = h.getCommandsList();

        for (int i = 0; i < commandToDel.size(); i++) {

            int index = commandToDel.get(i) - i;
            commandsList.remove(index);
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

    }

    @Override
    public void notifyHookCommandChanged(int hookId, int id, String value) {
        IHook h = hooks.get(hookId);
        List<IHookCommand> commandsList = h.getCommandsList();
        IHookCommand hc = commandsList.get(id);
        hc.setCommand(value);

    }
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

    }

    @Override
    public void notifyNewCommand(int id) {
        IHook h = hooks.get(id);
        if (h.getCommandsList() == null) {
            h.setCommandsList(new ListModel<IHookCommand, HookModel>(new ArrayList<IHookCommand>(),
                    ((HookModel) h), "commandsList"));
        }
        List<IHookCommand> commands = h.getCommandsList();
        commands.add(new HookCommandModel());
    }
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

        commands.add(new HookCommandModel());
    }

    @Override
    public void notifyNewHookAction() {
        IHook h = new HookModel();
        Stage s = getFirstStageUnreserved();
        h.setStage(s);
        hooks.add(h);
    }
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

        hooks.add(h);
    }

    @Override
    public void notifyStageAction(int id, String value) {
        IHook h = hooks.get(id);
        Stage s = Stage.valueOf(Stage.class, value);
        h.setStage(s);
    }
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

        view.clearHooks();
    }

    @Override
    public void notifyHookSelected(int hookId, boolean selected) {
        IHook h = hooks.get(hookId);
        if (selected) {
            hooksSelected.add(h);
        }
        else {
            MyRemove(hooksSelected, h);
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

    }

    private void MyRemove(List<IHook> list, IHook hook) {
        int index = -1;
        for (int i = 0; i < list.size(); i++) {
            IHook h = list.get(i);
            if (hook == h) {
                index = i;
            }
        }
        if (index != -1) {
View Full Code Here

Examples of fr.soleil.salsa.entity.IHook

            list.remove(index);
        }
    }

    public void notifyCommandSelected(int hookId, int commandId, boolean selected) {
        IHook h = hooks.get(hookId);
        if (h.getCommandsList() != null && h.getCommandsList().size() > commandId) {
            IHookCommand c = h.getCommandsList().get(commandId);

            if (selected) {
                commandsSelected.add(c);
            }
            else {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.