[OpenAjaxIDE] Handling 'default' values for properties
Jon Ferraiolo
jferrai at us.ibm.com
Tue Sep 23 12:20:49 PDT 2008
Javier,
I think I found the previous discussion. It was about the 'multiple'
attribute for the <options> element:
http://www.openajax.org/member/wiki/OpenAjax_Metadata_Specification_Datatypes#options_element
The above feature is related but not totally on target. For the 'multiple'
option, we have text that says that the value for an array must really be
an array (versus a JSON representation of an array as a string).
Your proposals below make sense to me.
Jon
Jon
Ferraiolo/Menlo
Park/IBM at IBMUS To
Sent by: Javier H Pedemonte/Austin/IBM at IBMUS
ide-bounces at opena cc
jax.org ide at openajax.org
Subject
[OpenAjaxIDE] Handling 'default'
09/23/2008 11:37 values for properties
AM
Hi Javier,
I am forwarding this to the IDE WG list so that we can discuss this at
today's phone call. I'll have to do some research. I am pretty sure we had
a discussion recently on a related subject, but my memory is failing me
right now.
Jon
Inactive hide details for Javier H Pedemonte/Austin/IBMJavier H
Pedemonte/Austin/IBM
Did the IDE/Gadgets groups ever discuss the format for the 'default'
attribute on the property elements? Since it has to be a string, we can
treat the default values as either a string or as a JSON encoded string.
Here's what I came up with, and what I'm trying to get working in the
refimpl:
DATATYPE DEFAULT VALUE HANDLED AS
===================================================================
String string
-------------------------------------------------------------------
Date string that can be passed
to Date()
-------------------------------------------------------------------
RegExp string that can be passed
to RegExp()
-------------------------------------------------------------------
Boolean
Number
Object JSON
Array
*
multiples
-------------------------------------------------------------------
JS class name N/A ('default' attr ignored
since JS class constructor
provides default values)
-------------------------------------------------------------------
Does this seem fair? There are some other possible datatypes that I
haven't figured out how to best handle...
Javier Pedemonte_______________________________________________
IDE mailing list
IDE at openajax.org
http://openajax.org/mailman/listinfo/ide
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://openajax.org/pipermail/ide/attachments/20080923/96a975e1/attachment.html
-------------- next part --------------
A non-text attachment was scrubbed...
Name: graycol.gif
Type: image/gif
Size: 105 bytes
Desc: not available
Url : http://openajax.org/pipermail/ide/attachments/20080923/96a975e1/attachment.gif
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pic06434.gif
Type: image/gif
Size: 1255 bytes
Desc: not available
Url : http://openajax.org/pipermail/ide/attachments/20080923/96a975e1/attachment-0001.gif
-------------- next part --------------
A non-text attachment was scrubbed...
Name: ecblank.gif
Type: image/gif
Size: 45 bytes
Desc: not available
Url : http://openajax.org/pipermail/ide/attachments/20080923/96a975e1/attachment-0002.gif
More information about the IDE
mailing list