Hi Daniel,
Thanks, I folded that patch in.
I also created a test case that illustrates the bug.

Interestingly, another bug is that if I create a Case Actor that has
a case with a pattern 
that is 

double-quote A double-quote

then the double quotes are not properly translated and the model
fails to open because the MoML looks like:

<entity name=""A"" class="ptolemy.actor.lib.hoc.Refinement">



    Hi ptolemy-hackers,
    The Case director does not find the correct Refinement when
    the control token is a string. Attached is a patch.
    Content-Type: text/plain; x-mac-type="0"; x-mac-creator="0";
    Content-Transfer-Encoding: 7bit
    Content-Disposition: attachment;
    Index: CaseDirector.java
    RCS file: /home/cvs/cvsanon/ptII/ptolemy/actor/lib/hoc/CaseDirector.java,v
    retrieving revision 1.10
    diff -r1.10 CaseDirector.java
    > import ptolemy.data.StringToken;
    <             String controlValue = container.control.getToken().toString()
    >             String controlValue;
    >             Token t = container.control.getToken();
    >             // if it's a string, use stringValue() otherwise there
    >             // are quotes around the string.
    >             if (t instanceof StringToken) {
    >                 controlValue = ((StringToken)t).stringValue();
    >             } else {
    >                 controlValue = t.toString();
    >             }

Posted to the ptolemy-hackers mailing list.  Please send administrative
mail for this list to: [EMAIL PROTECTED]

Reply via email to