This package provides classes and interfaces that implements a generic authentication module: User, Permission, PermissionGroup, and Role. It also provides DAOs and controllers, implemented using Generic DAO and Generic Controller
This package is completely technology-independent and has no dependencies except Generic DAO, Generic Controller and the JPA ORM annotations.
All DAOs in this package are implemented in Generic Authentication-Hibernate.
User represents a single user in an application and it is
meant to not be subclassed. Creating subclasses to represent
different types of user is an approach that has a serious
limitation: it does not support changing the type of a given
user during application execution, at least not elegantly.
That is why the Role class exists.
Role is an abstract class that represents some type of role
that an User can have. Each User
can have many Roles, but each Role instance
belongs to a single User.
Generic Authentication supports user permissions through its
Permission and PermissionGroup
classes. Each User can be associated to any number of
PermissionGroups. In addition, it is possible
to remove specific Permissions from an User,
through its removedPermissions property.