In a phrase: type and value checking
In a sentence: Accessor methods such as setFoo() now do type checking and
value checking on their arguments.
Details: ... So you can't pass in a string for a boolean:
obj.setSomeBool('s') # raises TypeError
Some numeric compatibility is allowed:
- ints can take longs that don't overflow the int range
- longs can take ints
- floats can take ints and longs
The date, time and datetime accessors no longer accept strings (such as
'2001-01-15') if you have an mx.DateTime.
For value checking:
- bools only take 0 or 1
- enums only take valid strings found in the enum def
Also: MiddleKit assumes that if you have DateTime, it is in the mx package,
as in:
from mx import DateTime
Caveat: Admittedly I haven't done good testing for when mx.DateTime is not
present.
Testing: As usual, this is all backed up by a new test suite and all test
suites pass.
_______________________________________________
Webware-discuss mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/webware-discuss