Examples of BooleanToken


Examples of ptolemy.data.BooleanToken

     *   actor with this name.
     */
    public Timer(CompositeEntity container, String name)
            throws NameDuplicationException, IllegalActionException {
        super(container, name);
        value = new Parameter(this, "value", new BooleanToken(true));
        input.setTypeEquals(BaseType.DOUBLE);
        output.setTypeSameAs(value);
    }
View Full Code Here

Examples of ptolemy.data.BooleanToken

        sceneGraphOut = new TypedIOPort(this, "sceneGraphOut");
        sceneGraphOut.setOutput(true);
        sceneGraphOut.setTypeEquals(SceneGraphToken.TYPE);

        accumulate = new Parameter(this, "accumulate", new BooleanToken(false));
    }
View Full Code Here

Examples of ptolemy.data.BooleanToken

     */
    public void fire() throws IllegalActionException {
        super.fire();
        for (int i = 0; i < input.getWidth(); i++) {
            if (input.hasToken(i)) {
                BooleanToken token = (BooleanToken) input.get(i);

                if (token.booleanValue()) {
                    output.send(i, token);
                }
            }
        }
    }
View Full Code Here

Examples of ptolemy.data.BooleanToken

            throws NameDuplicationException, IllegalActionException {
        super(container, name);
        output = new TypedIOPort(this, "output", false, true);
        time = new Parameter(this, "time", new DoubleToken(0.0));
        time.setTypeEquals(BaseType.DOUBLE);
        value = new Parameter(this, "value", new BooleanToken(true));
        output.setTypeSameAs(value);
    }
View Full Code Here

Examples of ptolemy.data.BooleanToken

        lowerRightX.setTypeEquals(BaseType.INT);

        lowerRightY = new Parameter(this, "lowerRightY", new IntToken(0));
        lowerRightY.setTypeEquals(BaseType.INT);

        rotatable = new Parameter(this, "rotatable", new BooleanToken(true));
        rotatable.setTypeEquals(BaseType.BOOLEAN);

        scalable = new Parameter(this, "scalable", new BooleanToken(false));
        scalable.setTypeEquals(BaseType.BOOLEAN);

        showAxes = new Parameter(this, "showAxes", new BooleanToken(false));
        showAxes.setTypeEquals(BaseType.BOOLEAN);

        translatable = new Parameter(this, "translatable", new BooleanToken(
                false));
        translatable.setTypeEquals(BaseType.BOOLEAN);

        backgroundColor = new ColorAttribute(this, "backgroundColor");
        backgroundColor.setExpression("{1.0, 1.0, 1.0, 1.0}");
View Full Code Here

Examples of ptolemy.data.BooleanToken

        super(container, name);

        length = new Parameter(this, "length", new IntToken(64));
        interpolation.setToken(new IntToken(16));
        excessBW = new Parameter(this, "excessBW", new DoubleToken(1.0));
        root = new Parameter(this, "root", new BooleanToken(false));
        symbolInterval = new Parameter(this, "symbolInterval", new IntToken(16));

        // Hide taps from UI.
        taps.setVisibility(Settable.NONE);
        _initialize();
View Full Code Here

Examples of ptolemy.data.BooleanToken

        sceneGraphOut = new TypedIOPort(this, "sceneGraphOut");
        sceneGraphOut.setOutput(true);
        sceneGraphOut.setTypeEquals(Scene2DToken.TYPE);

        accumulate = new Parameter(this, "accumulate", new BooleanToken(false));
    }
View Full Code Here

Examples of ptolemy.data.BooleanToken

        if (_debugging) {
            _debug(new StateEvent(this, _currentState));
        }

        BooleanToken resetToken = (BooleanToken) _lastChosenTransition.reset
                .getToken();

        if (resetToken.booleanValue()) {
            actors = _currentState.getRefinement();
            if (actors != null) {
                for (int i = 0; i < actors.length; ++i) {
                    if (_debugging) {
                        _debug(getFullName() + " initialize refinement: "
View Full Code Here

Examples of ptolemy.data.BooleanToken

                _parkingManager.update(updateMsg);
                debug.send(0, updateMsg);

                if ((_parkingManager.getAvailable().size() == 0) && !_isFull) {
                    _isFull = true;
                    isFull.send(0, new BooleanToken("true"));
                }

                if ((_parkingManager.getAvailable().size() > 0) && _isFull) {
                    _isFull = false;
                    isFull.send(0, new BooleanToken("false"));
                }
            }
        }
    }
View Full Code Here

Examples of ptolemy.data.BooleanToken

        if ((positionToken.length() != 3) || (axisToken.length() != 3)) {
            throw new IllegalActionException(
                    "viewerPosition and viewerRotaionAxis arrays must have length 3.");
        }

        BooleanToken equals = positionToken.isEqualTo(_position);
        equals = equals.and(axisToken.isEqualTo(_axis));
        equals = equals.and(angleToken.isEqualTo(_angle));

        if (!equals.booleanValue()) {
            double xPosition;
            double yPosition;
            double zPosition;
            double axisX;
            double axisY;
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.