Class: AccessRule

AccessRule()

A model that specifies a single permission set on a DataONEObject

Constructor

new AccessRule()

Source:

Extends

  • Backbone.Model

Methods

getSubjectInfo()

Gets and sets the subject info for the subjects in this access policy.
Source:

isGroup() → {boolean}

Returns true if the subbject set on this AccessRule is for a group of people.
Source:
Returns:
Type
boolean

parse(accessRuleXML) → {JSON}

Translates the access rule XML DOM into a JSON object to be set on the model.
Parameters:
Name Type Description
accessRuleXML Element An DOM element that contains a single access rule
Source:
Returns:
The Access Rule values to be set on this model
Type
JSON

serialize() → {object}

Takes the values set on this model's attributes and creates an XML string to be inserted into a DataONEObject's system metadata access policy.
Source:
Returns:
The access rule XML object or null if not created
Type
object