Package ptolemy.data.expr

Examples of ptolemy.data.expr.StringParameter


        // Create output port.
        level = new TypedIOPort(this, "level", false, true);
        level.setTypeEquals(BaseType.INT);

        // Identify the command to detect.
        command = new StringParameter(this, "command");
        command.addChoice("BRIGHT");
        command.addChoice("DIM");
        command.setExpression("BRIGHT");

        // Parameters.
        houseCode = new StringParameter(this, "houseCode");
        houseCode.setExpression("A");

        unitCode = new Parameter(this, "unitCode");
        unitCode.setTypeEquals(BaseType.INT);
        unitCode.setExpression("1");
View Full Code Here


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

        // Create input ports and port parameters.
        houseCode = new StringParameter(this, "houseCode");
        unitCode = new StringParameter(this, "unitCode");

        // The default value for the house code is A while the default value
        // for the unit code is 1. This is the normal x10 default address
        // value for most x10 devices.
        houseCode.setExpression("A");
View Full Code Here

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

        // Create input ports and port parameters.
        x10Interface = new StringParameter(this, "x10Interface");
        serialPortName = new StringParameter(this, "serialPortName");

        // The x10 interface is selectable, e.g. CM11A or CM17A. The x10
        // parameter allows the user to choose an interface.
        x10Interface.addChoice("CM11A");
        x10Interface.addChoice("CM17A");
View Full Code Here

        // Output true if detected is detected.
        detected.setTypeEquals(BaseType.BOOLEAN);

        // Identify the command to detect.
        command = new StringParameter(this, "command");
        command.addChoice("ON");
        command.addChoice("OFF");
        command.addChoice("ALL_LIGHTS_ON");
        command.addChoice("ALL_LIGHTS_OFF");
        command.addChoice("ALL_UNITS_OFF");
        command.setExpression("ON");

        // Parameters.
        houseCode = new StringParameter(this, "houseCode");
        houseCode.setExpression("A");

        unitCode = new Parameter(this, "unitCode");
        unitCode.setTypeEquals(BaseType.INT);
        unitCode.setExpression("1");
View Full Code Here

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

        // Parameters
        function = new StringParameter(this, "function");
        function.setExpression("exp");
        function.addChoice("exp");
        function.addChoice("log");
        function.addChoice("modulo");
        function.addChoice("sign");
View Full Code Here

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

        classNameForReduce = new StringParameter(this, "classNameForReduce");
        classNameForReduce.setExpression("ptolemy.actor.ptalon.lib.WordCount");

        inputKey = new TypedIOPort(this, "inputKey");
        inputKey.setInput(true);
        inputKey.setTypeEquals(BaseType.STRING);
View Full Code Here

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

        classNameForMap = new StringParameter(this, "classNameForMap");
        classNameForMap.setExpression("ptolemy.actor.ptalon.lib.WordCount");

        inputKey = new TypedIOPort(this, "inputKey");
        inputKey.setInput(true);
        inputKey.setTypeEquals(BaseType.STRING);
View Full Code Here

    public Subscriber(CompositeEntity container, String name)
            throws IllegalActionException, NameDuplicationException {
        // Set this up as input port.
        super(container, name);

        channel = new StringParameter(this, "channel");
        channel.setExpression("channel1");

        input = new TypedIOPort(this, "input", true, false);
        input.setMultiport(true);
        output = new TypedIOPort(this, "output", false, true);
View Full Code Here

        }

        // If there is an _applicationInitializer parameter, then
        // construct it.  The _applicationInitializer parameter contains
        // a string that names a class to be initialized.
        StringParameter applicationInitializerParameter = (StringParameter) configuration
                .getAttribute("_applicationInitializer", Parameter.class);

        if (applicationInitializerParameter != null) {
            String applicationInitializerClassName = applicationInitializerParameter
                    .stringValue();
            try {
                Class applicationInitializer = Class
                        .forName(applicationInitializerClassName);
                applicationInitializer.newInstance();
View Full Code Here

        squelch = new Parameter(this, "squelch");
        squelch.setExpression("-10.0");
        squelch.setTypeEquals(BaseType.DOUBLE);

        scale = new StringParameter(this, "scale");
        scale.setExpression("absolute");
        scale.addChoice("absolute");
        scale.addChoice("relative linear");
        scale.addChoice("relative amplitude decibels");
        scale.addChoice("relative power decibels");
View Full Code Here

TOP

Related Classes of ptolemy.data.expr.StringParameter

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.