Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.
Inheriting from Authenticator
[starting a new thread from comments in Understanding People]
Under the current arrangement, it looks like custom Authenticators have to be named Authenticator. That would prevent sub-classing the default Authenticator, since you can't have two classes with the same name. (Correct?) Now, I only want to change one or two methods in the default Authenticator, so it would make sense to me if there were an abstract class ("AbstractAuthenticator") that the default Authenticator inherited from (trivially), and that custom Authenticators could also inherit from. That way, the code could rely on the fact that the authentication module is called Authenticator, and we could take advantage of inheritance. Inheritance is especially important if we're going to be sharing our custom Authenticators, and want the non-custom methods to remain up-to-date.
The change is really quite easy, just rename the current Authenticator class to something else, and then define a new Authenticator class that extends the AbstractAuthenticator without adding any functionality.
Evan
Under the current arrangement, it looks like custom Authenticators have to be named Authenticator. That would prevent sub-classing the default Authenticator, since you can't have two classes with the same name. (Correct?) Now, I only want to change one or two methods in the default Authenticator, so it would make sense to me if there were an abstract class ("AbstractAuthenticator") that the default Authenticator inherited from (trivially), and that custom Authenticators could also inherit from. That way, the code could rely on the fact that the authentication module is called Authenticator, and we could take advantage of inheritance. Inheritance is especially important if we're going to be sharing our custom Authenticators, and want the non-custom methods to remain up-to-date.
The change is really quite easy, just rename the current Authenticator class to something else, and then define a new Authenticator class that extends the AbstractAuthenticator without adding any functionality.
Evan
0
This discussion has been closed.
Comments