Module: server/documentsManager

Methods

(static) getDocumentAsync(authorizationHeader, documentName) → {object}

gets a document initialized with its required data
Parameters:
Name Type Description
authorizationHeader string HTTP header variable `authorization` from the current request
documentName string document identifier which used when registered with registerDocument function
Source:
Returns:
document initialized with its required data
Type
object

(static) registerDocument(documentName, documentCreatorAsync)

registers a document's creation function along its identifier
Parameters:
Name Type Description
documentName string document identifier
documentCreatorAsync func creation function which gets authorization header and returns the data and pages of the document
Source: