Package ptolemy.data

Examples of ptolemy.data.IntToken


                } catch (NameDuplicationException e) {
                    throw new InternalErrorException(e);
                }
            }

            rate.setToken(new IntToken(1));

            String portName = port.getName();
            Attribute attribute = getAttribute(portName);

            if (attribute == null) {
View Full Code Here


        trigger.setMultiport(true);

        // parameters - Ordering here sets the order they show up in Vergil
        localSocketNumber = new Parameter(this, "localSocketNumber");
        localSocketNumber.setTypeEquals(BaseType.INT);
        localSocketNumber.setToken(new IntToken(4004));

        actorBufferLength = new Parameter(this, "actorBufferLength");
        actorBufferLength.setTypeEquals(BaseType.INT);
        actorBufferLength.setToken(new IntToken(440));

        platformBufferLength = new Parameter(this, "platformBufferLength");
        platformBufferLength.setTypeEquals(BaseType.INT);
        platformBufferLength.setToken(new IntToken(64));

        setPlatformBufferLength = new Parameter(this,
                "setPlatformBufferLength", new BooleanToken(false));
        setPlatformBufferLength.setTypeEquals(BaseType.BOOLEAN);
View Full Code Here

            _syncFireAndThread.notifyAll();
        } // sync

        if (!useDefaultOutput) {
            returnAddress.broadcast(new StringToken(_returnAddress));
            returnSocketNumber.broadcast(new IntToken(_returnSocketNumber));
            output.broadcast(_outputToken);
        } else {
            // No fresh data, so use the default output.
            // (If repeat parameter were implemented,
            //  would test it here and, if true, would
            //  repeat the most recent output instead
            //  of outputting the default, provided
            //  there is a previous output to repeat.)
            // _defaultOutputToken == null when user has entered blank
            // parameter.  Take this as a directive to not broadcast a
            // token in this case.
            if (_defaultOutputToken == null) {
                if (_debugging) {
                    _debug("DO NOT Broadcast ANY output (blank default)");
                }
            } else {
                if (_debugging) {
                    _debug("Broadcast default outputs");
                }

                synchronized (_syncDefaultOutputs) {
                    // Ensure that any change to the default output parameters
                    // occurs atomically with respect to its use here.
                    returnAddress.broadcast(new StringToken(
                            _defaultReturnAddress));
                    returnSocketNumber.broadcast(new IntToken(
                            _defaultReturnSocketNumber));
                    output.broadcast(_defaultOutputToken);
                }
            }
        }
View Full Code Here

     */
    public JAIBoxFilter(CompositeEntity container, String name)
            throws IllegalActionException, NameDuplicationException {
        super(container, name);

        width = new Parameter(this, "width", new IntToken(3));
        height = new Parameter(this, "height", new IntToken(3));
    }
View Full Code Here

     */
    public JAIConstant(CompositeEntity container, String name)
            throws IllegalActionException, NameDuplicationException {
        super(container, name);
        output.setTypeEquals(BaseType.OBJECT);
        width = new Parameter(this, "width", new IntToken(0));
        height = new Parameter(this, "height", new IntToken(0));
        bandValues = new Parameter(this, "bandValues", new ArrayToken(
                BaseType.INT, _defaultValues));
        dataFormat = new StringAttribute(this, "dataFormat");
        dataFormat.setExpression("byte");
        _dataFormat = _BYTE;
View Full Code Here

    public void fire() throws IllegalActionException {
        super.fire();
        // Broadcast key presses.
        if (_upKeyPressed) {
            _upKeyPressed = false;
            upArrow.broadcast(new IntToken(1));
        }

        if (_leftKeyPressed) {
            _leftKeyPressed = false;
            leftArrow.broadcast(new IntToken(1));
        }

        if (_rightKeyPressed) {
            _rightKeyPressed = false;
            rightArrow.broadcast(new IntToken(1));
        }

        if (_downKeyPressed) {
            _downKeyPressed = false;
            downArrow.broadcast(new IntToken(1));
        }

        // Broadcast key releases.
        if (_upKeyReleased) {
            _upKeyReleased = false;
            upArrow.broadcast(new IntToken(0));
        }

        if (_leftKeyReleased) {
            _leftKeyReleased = false;
            leftArrow.broadcast(new IntToken(0));
        }

        if (_rightKeyReleased) {
            _rightKeyReleased = false;
            rightArrow.broadcast(new IntToken(0));
        }

        if (_downKeyReleased) {
            _downKeyReleased = false;
            downArrow.broadcast(new IntToken(0));
        }
    }
View Full Code Here

        interpolationType = new StringAttribute(this, "interpolationType");
        interpolationType.setExpression("bilinear");
        _interpolationType = _BILINEAR;

        subSampleBits = new Parameter(this, "subSampleBits", new IntToken(8));

        input.setTypeEquals(BaseType.OBJECT);
        output.setTypeEquals(BaseType.OBJECT);
    }
View Full Code Here

    public Plotter(CompositeEntity container, String name)
            throws IllegalActionException, NameDuplicationException {
        super(container, name);

        startingDataset = new Parameter(this, "startingDataset",
                new IntToken(0));
        startingDataset.setTypeEquals(BaseType.INT);
    }
View Full Code Here

     */
    public JAICrop(CompositeEntity container, String name)
            throws IllegalActionException, NameDuplicationException {
        super(container, name);

        xOrigin = new Parameter(this, "xOrigin", new IntToken(0));
        yOrigin = new Parameter(this, "yOrigin", new IntToken(0));

        width = new Parameter(this, "width", new IntToken(0));
        height = new Parameter(this, "height", new IntToken(0));
    }
View Full Code Here

        interpolationType.setExpression("bilinear");
        _interpolationType = _BILINEAR;

        output.setTypeEquals(BaseType.OBJECT);

        subSampleBits = new Parameter(this, "subSampleBits", new IntToken(8));

        xOrigin = new Parameter(this, "xOrigin", new IntToken(0));
        yOrigin = new Parameter(this, "yOrigin", new IntToken(0));
    }
View Full Code Here

TOP

Related Classes of ptolemy.data.IntToken

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.