Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

First, we remove the dependence on ORM for permissions. Insead calling ORM supported methods on the Weblog and User classes, the Roller front-end will call the Roller UserManager to access permissions information. We'll add these new methods to accommodate that:

New methods in UserManager

Code Block
public Set<WeblogPermission> getWeblogPermissions(Weblog weblog)
public Set<WeblogPermission> getUserPermissions(User user)
public void grantPermissions(String username, WeblogPermission perm)
public void removePermission(String username, WeblogPermission perm)
public int getUserCount(Weblog weblog)
public int getAdminCount(Weblog weblog)

...

For example, this API allows you to grant permissions on specific objects and uses a mask for permissions as we do now in Roller.

User Permissions API

UserPermissions interface methods

...