*
* @return full list of permissions for this user.
*/
@XmlTransient
public Set<Permission> getPermissions() {
PermissionFactory permFactory = new PermissionFactory();
Set<Permission> perms = new HashSet<Permission>();
for (Role r : getRoles()) {
perms.addAll(permFactory.createPermissions(this, r.getPermissions()));
}
perms.addAll(this.permissions);
return perms;
}