blob: c09b1cd9f71337a5c82b5af201b62222ed486c65 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
|
/*
MIT License http://www.opensource.org/licenses/mit-license.php
Author Tobias Koppers @sokra
*/
"use strict";
var Source = require("./Source");
var SourceNode = require("source-map").SourceNode;
var SourceListMap = require("source-list-map").SourceListMap;
class RawSource extends Source {
constructor(value) {
super();
this._value = value;
}
source() {
return this._value;
}
map(options) {
return null;
}
node(options) {
return new SourceNode(null, null, null, this._value);
}
listMap(options) {
return new SourceListMap(this._value);
}
updateHash(hash) {
hash.update(this._value);
}
}
module.exports = RawSource;
|