Options
All
  • Public
  • Public/Protected
  • All
Menu

Checks if the given WebID belongs to a group that has access. Implements the behaviour of groups from the WAC specification.

Fetched results will be stored in an ExpiringStorage.

Requires a storage that can store JS objects. expiration parameter is how long entries in the cache should be stored in seconds, defaults to 3600.

Hierarchy

Index

Constructors

Properties

cache: ExpiringStorage<string, Promise<Store<Quad, Quad, Quad, Quad>>>
expiration: number

Methods

  • Checks if the input can be handled by this class. If it cannot handle the input, rejects with an error explaining why.

    Parameters

    Returns Promise<void>

    A promise resolving if the input can be handled, rejecting with an Error if not.

  • fetchCachedQuads(url: string): Promise<Store<Quad, Quad, Quad, Quad>>
  • isMemberOfGroup(webId: string, group: Term): Promise<boolean>
  • Checks if the given agent is member of a given vCard group.

    Parameters

    • webId: string

      WebID of the agent that needs access.

    • group: Term

      URL of the vCard group that needs to be checked.

    Returns Promise<boolean>

    If the agent is member of the given vCard group.