seeing the discussion about JSON
it made me think about code introspection
and wondering what kind of "language element" developpers
will have to do that in ES4 ?
and how far serialization/deserialization mecanism will be able to go ?
taking AS3 as exemple,
you can do only introspection using
flash.utils.describeType function
my problem with that are:
it's vendor specific, should it not be better to have
such mecanism defined in the ES4 language ?
in AS3 you can only access public members
which is good for security but bad for serialization/deserialization
I understand where JSON is heading,
but is it the only language element that is planed ?
can we really not have something as toSource() and its counterpart
fromSource() ?
Do I overlook what would be possible to do if developpers can access
the internal namespace ?
What if people want to do more than JSON and serialize/deseiralize
"new Date()" or other custom class ?
what would be the options ?
zwetan
Hello,
seeing the discussion about JSON
it made me think about code introspection
and wondering what kind of "language element" developpers
will have to do that in ES4 ?
and how far serialization/deserialization mecanism will be able to go ?
taking AS3 as exemple,
you can do only introspection using
flash.utils.describeType function
my problem with that are:
- it's vendor specific, should it not be better to have
such mecanism defined in the ES4 language ?
- in AS3 you can only access public members
which is good for security but bad for serialization/deserialization
I understand where JSON is heading,
but is it the only language element that is planed ?
can we really not have something as toSource() and its counterpart
fromSource() ?
Do I overlook what would be possible to do if developpers can access
the internal namespace ?
What if people want to do more than JSON and serialize/deseiralize
"new Date()" or other custom class ?
what would be the options ?
zwetan
Hello,
seeing the discussion about JSON it made me think about code introspection and wondering what kind of "language element" developpers will have to do that in ES4 ? and how far serialization/deserialization mecanism will be able to go ?
taking AS3 as exemple, you can do only introspection using flash.utils.describeType function
my problem with that are:
I understand where JSON is heading, but is it the only language element that is planed ? can we really not have something as toSource() and its counterpart fromSource() ? Do I overlook what would be possible to do if developpers can access the internal namespace ?
What if people want to do more than JSON and serialize/deseiralize "new Date()" or other custom class ? what would be the options ?
zwetan