On Jun 2, 12:40 pm, Antoon Pardon <[EMAIL PROTECTED]> wrote: > I think you completed missed the point. > > This is just a proof of concept thing. In a real example there would > of course no Set en Get methods but just methods that in the course > of their execution would access or update the hidden attributes
I have to agree with Banks here, you have not provided an example of data hiding. It does not discriminate between attribute access from within and from outside the class. You just assume that the attribute named 'hidden' will be left alone. Also naming it hidden is stupid as it is visible. What you need is a mechanism that will thrown an exception whenever an attribue is accessed from outside the class, but not from inside. The mechanism must also be impossible to override with additional code. If Ada is what you want, Ada is what you should use. -- http://mail.python.org/mailman/listinfo/python-list