Package fr.soleil.salsa.client.entity.event

Examples of fr.soleil.salsa.client.entity.event.Range1DModel


     * Adds a range and associated trajectories for the model and the view.
     */
    @Override
    public void notifyNewRangeAction() {
        if (this.config != null) {
            Range1DModel rangeToAdd = new Range1DModel();
            rangeToAdd.setDimension(((IConfig1D) config).getDimensionX());
            IDimension1D dimension = ((IConfig1D) config).getDimensionX();
            rangeToAdd.setIntegrationTime(1.0);
            rangeToAdd.setStepsNumber(1);
            this.rangeModelsList.add(rangeToAdd);
            ((IConfig1D) config).getDimensionX().getRangesXList().add(rangeToAdd);
            IRange1D range = ((IConfig1D) config).getDimensionX().getRangesXList().get(
                    ((IConfig1D) config).getDimensionX().getRangesXList().size() - 1);
            ((Range1DModel) range).addListener(listenerRange1D);

            for (int i = 0; i < this.actuatorModelsList.size(); i++) {
                Trajectory1DModel trajectory1DModelToAdd = new Trajectory1DModel();
                trajectory1DModelToAdd.setBeginPosition(0.0);
                trajectory1DModelToAdd.setEndPosition(0.0);
                trajectory1DModelToAdd.setDelta(0.0);
                trajectory1DModelToAdd.setRelative(false);
                trajectory1DModelToAdd.setSpeed(0.0);

                rangeToAdd.getTrajectoriesList().add(trajectory1DModelToAdd);
                trajectory1DModelToAdd.setRange(rangeToAdd);
                trajectory1DModelToAdd.setActuator(actuatorModelsList.get(i));

                dimension.getTrajectoriesList().add(trajectory1DModelToAdd);
                ITrajectory1D t = dimension.getTrajectoriesList().get(
View Full Code Here


        this.actuatorModelsList.clear();
        List<IRange1D> rangeList = ((IConfig1D) config).getDimensionX().getRangesXList();
        List<IActuator> actuatorsList = ((IConfig1D) config).getDimensionX().getActuatorsList();

        for (int i = 0; i < rangeList.size(); i++) {
            Range1DModel rangeToAdd = (Range1DModel) rangeList.get(i);
            this.rangeModelsList.add(rangeToAdd);
        }

        for (int i = 0; i < actuatorsList.size(); i++) {
            this.actuatorModelsList.add((ActuatorModel) actuatorsList.get(i));
View Full Code Here

     * Adds a range and associated trajectories for the model and the view.
     */
    @Override
    public void notifyNewRangeAction() {
        if (this.config != null) {
            Range1DModel rangeToAdd = new Range1DModel();
            rangeToAdd.setDimension(((IConfig1D) config).getDimensionX());
            IDimension1D dimension = ((IConfig1D) config).getDimensionX();
            rangeToAdd.setIntegrationTime(1.0);
            rangeToAdd.setStepsNumber(1);
            this.rangeModelsList.add(rangeToAdd);
            ((IConfig1D) config).getDimensionX().getRangesXList().add(rangeToAdd);
            IRange1D range = ((IConfig1D) config).getDimensionX().getRangesXList().get(
                    ((IConfig1D) config).getDimensionX().getRangesXList().size() - 1);
            ((Range1DModel) range).addListener(listenerRange1D);

            for (int i = 0; i < this.actuatorModelsList.size(); i++) {
                Trajectory1DModel trajectory1DModelToAdd = new Trajectory1DModel();
                trajectory1DModelToAdd.setBeginPosition(0.0);
                trajectory1DModelToAdd.setEndPosition(0.0);
                trajectory1DModelToAdd.setDelta(0.0);
                trajectory1DModelToAdd.setRelative(false);
                trajectory1DModelToAdd.setSpeed(0.0);

                rangeToAdd.getTrajectoriesList().add(trajectory1DModelToAdd);
                trajectory1DModelToAdd.setRange(rangeToAdd);
                trajectory1DModelToAdd.setActuator(actuatorModelsList.get(i));

                dimension.getTrajectoriesList().add(trajectory1DModelToAdd);
                ITrajectory1D t = dimension.getTrajectoriesList().get(
View Full Code Here

        this.actuatorModelsList.clear();
        List<IRange1D> rangeList = ((IConfig1D) config).getDimensionX().getRangesXList();
        List<IActuator> actuatorsList = ((IConfig1D) config).getDimensionX().getActuatorsList();

        for (int i = 0; i < rangeList.size(); i++) {
            Range1DModel rangeToAdd = (Range1DModel) rangeList.get(i);
            this.rangeModelsList.add(rangeToAdd);
        }

        for (int i = 0; i < actuatorsList.size(); i++) {
            this.actuatorModelsList.add((ActuatorModel) actuatorsList.get(i));
View Full Code Here

TOP

Related Classes of fr.soleil.salsa.client.entity.event.Range1DModel

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.