Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F101472934
document.js
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Mon, Feb 10, 19:16
Size
654 B
Mime Type
text/x-c++
Expires
Wed, Feb 12, 19:16 (1 d, 14 h)
Engine
blob
Format
Raw Data
Handle
24155839
Attached To
rOACCT Open Access Compliance Check Tool (OACCT)
document.js
View Options
'use strict'
let Container = require('./container')
let LazyResult, Processor
class Document extends Container {
constructor(defaults) {
// type needs to be passed to super, otherwise child roots won't be normalized correctly
super({ type: 'document', ...defaults })
if (!this.nodes) {
this.nodes = []
}
}
toResult(opts = {}) {
let lazy = new LazyResult(new Processor(), this, opts)
return lazy.stringify()
}
}
Document.registerLazyResult = dependant => {
LazyResult = dependant
}
Document.registerProcessor = dependant => {
Processor = dependant
}
module.exports = Document
Document.default = Document
Event Timeline
Log In to Comment