mirror of
https://github.com/react/react-native-devtools-frontend.git
synced 2026-10-05 19:41:12 +08:00
The breaking changes listed in https://github.com/karma-runner/karma/releases/tag/v5.0.0 do not apply to us. This should also include support for Edgium per https://github.com/karma-runner/karma/pull/3440 R=jacktfranklin@chromium.org DISABLE_THIRD_PARTY_CHECK=Update karma Bug: 1068145 Change-Id: I7567b2db14dbf59aaf9c091220157bf55d155810 Reviewed-on: https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/2144050 Commit-Queue: Jack Franklin <jacktfranklin@chromium.org> Reviewed-by: Jack Franklin <jacktfranklin@chromium.org> Auto-Submit: Tim van der Lippe <tvanderlippe@chromium.org>
38 lines
878 B
JavaScript
38 lines
878 B
JavaScript
'use strict'
|
|
|
|
/**
|
|
* File object used for tracking files in `file-list.js`.
|
|
*/
|
|
class File {
|
|
constructor (path, mtime, doNotCache, type, isBinary) {
|
|
// used for serving (processed path, eg some/file.coffee -> some/file.coffee.js)
|
|
this.path = path
|
|
|
|
// original absolute path, id of the file
|
|
this.originalPath = path
|
|
|
|
// where the content is stored (processed)
|
|
this.contentPath = path
|
|
|
|
// encodings format {[encodingType]: encodedContent}
|
|
// example: {gzip: <Buffer 1f 8b 08...>}
|
|
this.encodings = Object.create(null)
|
|
|
|
this.mtime = mtime
|
|
this.isUrl = false
|
|
|
|
this.doNotCache = doNotCache === undefined ? false : doNotCache
|
|
|
|
this.type = type
|
|
|
|
// Tri state: null means probe file for binary.
|
|
this.isBinary = isBinary === undefined ? null : isBinary
|
|
}
|
|
|
|
toString () {
|
|
return this.path
|
|
}
|
|
}
|
|
|
|
module.exports = File
|