[kepler-dev] [Bug 1845] - user input for port type should not be case sensitive

Edward A. Lee eal at eecs.berkeley.edu
Mon Dec 19 10:39:14 PST 2005


Types are specified in Ptolemy II as "prototypes". That is, a type
is given by giving an expression that resolves to the type.
Hence, "double" is actually a variable named "double" with value
0.0.  The expression evaluator will confirm this...

The expression language in Ptolemy II is case sensitive.
As in Java, C++, and every other programming language since Fortran,
variable names are case sensitive. Foo is not the same variable as
foo.

So if you really want "double" and "Double" to evaluate to the same
thing, the right way to do this is to define two variables.

As a general rule, giving users multiple ways to specify the same
thing is not necessarily good.  It makes it hard for people to read
each other's work. If I always use "double", then I will be puzzled
when I see a workflow that uses "DOUBLE", and I will wonder if it
means something different...  So I'm not sure I understand
the basic philosophy here...

Edward

At 08:06 AM 12/19/2005 -0800, bugzilla-daemon at ecoinformatics.org wrote:
>http://bugzilla.ecoinformatics.org/show_bug.cgi?id=1845
>
>
>
>
>
>------- Additional Comments From ldowney at lternet.edu  2005-12-19 08:06 -------
>The issue here involves a couple of different things.
>
>1.  when first tested, the user had to exactly type something in for the
>system to recognize it.  That is way too much burden on the user.  I very 
>much
>doubt there are many users that really want to assign string and STRING to be
>two different types! :-)
>
>2.  the second issue is that a set of common data types should be offered to
>the user so they don't have to type at all if they are choosing a standard
>type.
>
>3.  it should really be a combo box so a user can indeed add/specify a type
>that is not part of the standard set (I can't remember where but I wrote a 
>bug
>that talked about using combo boxes where possible in whatever situation we
>had that there was generally a standard set of choices but also allows for
>customization by the user.  And if a user created a new type for example
>called String, then for that user String should subsequently show up as a
>choice.  We could also consider allowing users to "globally" add new types so
>they are available for other users.)
>_______________________________________________
>Kepler-dev mailing list
>Kepler-dev at ecoinformatics.org
>http://mercury.nceas.ucsb.edu/ecoinformatics/mailman/listinfo/kepler-dev

------------
Edward A. Lee
Professor, Chair of the EE Division, Associate Chair of EECS
231 Cory Hall, UC Berkeley, Berkeley, CA 94720
phone: 510-642-0253 or 510-642-0455, fax: 510-642-2845
eal at eecs.Berkeley.EDU, http://ptolemy.eecs.berkeley.edu/~eal  



More information about the Kepler-dev mailing list