so, something cool about security of your screens/actions/etc can be easily
had by simply creating a chain of extends.
For example you could make a Screen class called RequireLoginFirst that
extends WebMacroSiteSecurityScreen. Then, any screen that extends RLF would
then require someone to login first.
But, say you not only want to require login first, but you also want to make
sure they have admin permissions...you could do a chain of something like
this:
RequireLoginFirst extends RequireAdminPermissions extends
WebMacroSiteSecurityScreen
By calling super() within the isAuthorized() methoded within
RequireLoginFirst you would not only have the user require a login first,
but also have the check done for admin permissions.
This seems totally cool to me. The classes that extend these classes don't
need to know anything about what is happening behind the scenes...only that
they are extending base functionality (no need to even call super!). On top
of it, you can *still* override the isAuthorized() method in the
implementation screens to do even more security checking (would need a call
to super(), but not that big of a deal in this case since you are already
doing a lot of extra work for a single screen).
Wow...totally powerful and totally easy.
-jon
------------------------------------------------------------
To subscribe: [EMAIL PROTECTED]
To unsubscribe: [EMAIL PROTECTED]
Problems?: [EMAIL PROTECTED]