Package ptolemy.moml

Examples of ptolemy.moml.SharedParameter$SharedParameterRegistry


     * @exception NameDuplicationException If the container already has an
     * actor with this name.
     */
    public RandomSource(CompositeEntity container, String name) throws NameDuplicationException, IllegalActionException  {
        super(container, name);
        seed = new SharedParameter(this, "seed", RandomSource.class, "0L");
        seed.setTypeEquals(BaseType.LONG);
        resetOnEachRun = new SharedParameter(this, "resetOnEachRun", RandomSource.class, "false");
        resetOnEachRun.setTypeEquals(BaseType.BOOLEAN);
        new SingletonParameter(trigger, "_showName").setToken(BooleanToken.TRUE);
    }
View Full Code Here


     *   actor with this name.
     */
    public RandomSource(CompositeEntity container, String name)
            throws NameDuplicationException, IllegalActionException {
        super(container, name);
        seed = new SharedParameter(this, "seed", RandomSource.class, "0L");
        seed.setTypeEquals(BaseType.LONG);

        resetOnEachRun = new SharedParameter(this, "resetOnEachRun",
                RandomSource.class, "false");
        resetOnEachRun.setTypeEquals(BaseType.BOOLEAN);

        new SingletonParameter(trigger, "_showName")
                .setToken(BooleanToken.TRUE);
View Full Code Here

        tolerance = new Parameter(this, "tolerance");
        tolerance.setExpression("1.0E-9");
        tolerance.setTypeEquals(BaseType.DOUBLE);

        trainingMode = new SharedParameter(this, "trainingMode", getClass(),
                "false");
        trainingMode.setTypeEquals(BaseType.BOOLEAN);

        input.setMultiport(false);
    }
View Full Code Here

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

        generatorClass = new SharedParameter(this, "generatorClass",
                ColtRandomSource.class, "DRand");
        generatorClass.setStringMode(true);

        generatorClass.addChoice("DRand");
        generatorClass.addChoice("MersenneTwister (MT19937)");
View Full Code Here

            target = new StringParameter(this, "target");
            target.setExpression("ptII");

            // Set simulate to true.
            // NOTE: only the top level value of this parameter matters.
            simulate = new SharedParameter(this, "simulate", PtinyOSDirector.class, "true");
            simulate.setTypeEquals(BaseType.BOOLEAN);

            // Set to the default node name.
            baseStation = new SharedParameter(this, "baseStation",
                    PtinyOSDirector.class, "\"MicaBoard\"");

            // Set command and event ports for TOSSIM.
            commandPort = new PtinyOSNodeParameter(this, "commandPort", 2);
            commandPort.setExpression("10584");
View Full Code Here

    // Initialize parameters.
    private void _initializeParameters() {
        // This must happen first before any time objects get created.
        try {
            timeResolution = new SharedParameter(this, "timeResolution",
                    Director.class, "1E-10");

            // Since by default directors have no time, this is
            // invisible.
            timeResolution.setVisibility(Settable.NONE);
View Full Code Here

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

        sampleRate = new SharedParameter(this, "sampleRate",
                LiveSoundActor.class);
        sampleRate.setExpression("8000");
        sampleRate.setTypeEquals(BaseType.INT);

        bitsPerSample = new SharedParameter(this, "bitsPerSample",
                LiveSoundActor.class);
        bitsPerSample.setExpression("16");
        bitsPerSample.setTypeEquals(BaseType.INT);

        channels = new SharedParameter(this, "channels", LiveSoundActor.class);
        channels.setExpression("1");
        channels.setTypeEquals(BaseType.INT);

        transferSize = new SharedParameter(this, "transferSize",
                LiveSoundActor.class);
        transferSize.setExpression("128");
        transferSize.setTypeEquals(BaseType.INT);

        bufferSize = new SharedParameter(this, "bufferSize",
                LiveSoundActor.class);
        bufferSize.setExpression("1024");
        bufferSize.setTypeEquals(BaseType.INT);
    }
View Full Code Here

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

        sampleRate = new SharedParameter(this, "sampleRate", SoundActor.class);
        sampleRate.setExpression("8000");
        sampleRate.setTypeEquals(BaseType.INT);

        bytesPerSample = new SharedParameter(this, "bytesPerSample",
                SoundActor.class);
        bytesPerSample.setExpression("2");
        bytesPerSample.setTypeEquals(BaseType.INT);

        channels = new SharedParameter(this, "channels", SoundActor.class);
        channels.setExpression("1");
        channels.setTypeEquals(BaseType.INT);

        bufferSize = new SharedParameter(this, "bufferSize", SoundActor.class);
        bufferSize.setExpression("1024");
        bufferSize.setTypeEquals(BaseType.INT);
    }
View Full Code Here

        tolerance = new Parameter(this, "tolerance");
        tolerance.setExpression("1.0E-9");
        tolerance.setTypeEquals(BaseType.DOUBLE);

        trainingMode = new SharedParameter(this, "trainingMode", getClass(),
                "false");
        trainingMode.setTypeEquals(BaseType.BOOLEAN);

        // Note that in Publisher, the input is a multiport.
        input.setMultiport(false);
View Full Code Here

            throws NameDuplicationException, IllegalActionException {
        super(container, name);
        correctExceptionMessage = new StringParameter(this,
                "correctExceptionMessage");
        correctExceptionMessage.setExpression("");
        trainingMode = new SharedParameter(this, "trainingMode", getClass(),
                "false");
        trainingMode.setTypeEquals(BaseType.BOOLEAN);
        _invoked = false;
    }
View Full Code Here

TOP

Related Classes of ptolemy.moml.SharedParameter$SharedParameterRegistry

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.