anchor.diff:      ).
   
   %%--------------------------------------------------------------------
  +%% @doc A privilege level of a handle_service user.
  +%%--------------------------------------------------------------------
  +-spec handle_service_user() -> [handle_service_privilege()].
  +handle_service_user() ->
  +    [view_handle_service].
  +
  +%%--------------------------------------------------------------------
  +%% @doc A privilege level of a handle_service administrator. This level contains all
  +%% atoms representing handle_service privileges.
  +%% @end
  +%%--------------------------------------------------------------------
  +-spec handle_service_admin() -> [handle_service_privilege()].
  +handle_service_admin() ->
  +    ordsets:union(
  +        handle_service_user(),
  +        ordsets:from_list([
  +            register_handle_service,
  +            list_handle_services,
  +            delete_handle_service,
  +            modify_handle_service,
  +            view_handle_service
  +        ])
  +    ).
  +
  +%%--------------------------------------------------------------------
  +%% @doc A privilege level of a handle user.
  +%%--------------------------------------------------------------------
  +-spec handle_user() -> [handle_privilege()].
  +handle_user() ->
  +    [view_handle].
  +
  +%%--------------------------------------------------------------------
  +%% @doc A privilege level of a handle administrator. This level contains all
  +%% atoms representing handle privileges.
  +%% @end
  +%%--------------------------------------------------------------------
  +-spec handle_admin() -> [handle_privilege()].
  +handle_admin() ->
  +    ordsets:union(
  +        handle_user(),
  +        ordsets:from_list([
  +            register_handle,
  +            list_handles,
  +            delete_handle,
  +            modify_handle,
  +            view_handle
  +        ])
  +    ).
  +
  +%%--------------------------------------------------------------------
   %% @doc All atoms representing space privileges.
   %% @equiv space_admin()
   %%--------------------------------------------------------------------
  
positive.code: group_set_privileges | group_remove | group_leave_space |
  group_view_data | group_create_space_token |
  group_join_group | group_invite_group | group_remove_group.
  
  %%%===================================================================
  %%% API
  
negative.code: -spec group_privileges() -> [group_privilege()].
  group_privileges() ->
      group_admin().
  
  %%--------------------------------------------------------------------
  %% @doc All atoms representing handle_service privileges.
  %% @equiv handle_service_admin()
  %%--------------------------------------------------------------------
  -spec handle_service_privileges() -> [handle_service_privilege()].
  handle_service_privileges() ->
      handle_service_admin().
  
  %%--------------------------------------------------------------------
  %% @doc All atoms representing handle privileges.
  %% @equiv handle_admin()
  %%--------------------------------------------------------------------
  -spec handle_privileges() -> [handle_privilege()].
  handle_privileges() ->
      handle_admin().