Re-implementing Vs Overloading methods

Discussions about design and architecture principles, including native JADE systems and JADE interoperating with other technologies
ConvertFromOldNGs
Posts: 5321
Joined: Wed Aug 05, 2009 5:19 pm

Re: Re-implementing Vs Overloading methods

Postby ConvertFromOldNGs » Fri Aug 07, 2009 11:18 am

by Dean Cooper >> Wed, 2 Feb 2000 4:27:37 GMT
Makes perfect sense, and as far as I can tell is not possible in Jade because you cannot protect the constructor.

Currently in JADE you cannot (easily) implement the concept of a protected constructor. We'd like to address in the future. Internally we have the concept of "access classes" which will allow you, for a given class, to specify the classes whose methods are allowed to create instances of that class. In fact, structural support for this already exists in the meta-schema, but it needs to be exposed through the development environment and the compiler. With this feature you would be able to enforce that only methods of your factory class can create instances of a particular target class.

Dean.


Return to “Design and Architecture”

Who is online

Users browsing this forum: No registered users and 9 guests