I would like to know the benefits for javascripts' prototype objects as
compared to say java class-based objects.
The main points that I have on my mind are:
1. Is there a way to mark properties in prototype-based langauges as 'final
or 'private' as you can in java so that some properties are 'hidden' from
child objects.
2. Is there a way for objects to limit the delete function in javascript, or
any prototype-based langauge, to prevent to object structure from been
'broken'. ie if an object 'a' has a child object 'b', can object 'b' rely on
the fact object 'a' provides the features the next time object 'b' is used.
thanks in advance
Neil Morris
--
my IE6 favorites for import into Netscape/Internet Explorer
compared to say java class-based objects.
The main points that I have on my mind are:
1. Is there a way to mark properties in prototype-based langauges as 'final
or 'private' as you can in java so that some properties are 'hidden' from
child objects.
2. Is there a way for objects to limit the delete function in javascript, or
any prototype-based langauge, to prevent to object structure from been
'broken'. ie if an object 'a' has a child object 'b', can object 'b' rely on
the fact object 'a' provides the features the next time object 'b' is used.
thanks in advance
Neil Morris
--
my IE6 favorites for import into Netscape/Internet Explorer
Comment