PHP 8.2.30
Preview: lazy_transform.js Size: 1.54 KB
/opt/alt/alt-nodejs19/root/lib/node_modules/npm/node_modules/readable-stream/lib/internal/streams/lazy_transform.js

// LazyTransform is a special type of Transform stream that is lazily loaded.
// This is used for performance with bi-API-ship: when two APIs are available
// for the stream, one conventional and one non-conventional.
'use strict'

const { ObjectDefineProperties, ObjectDefineProperty, ObjectSetPrototypeOf } = require('../../ours/primordials')
const stream = require('../../stream')
const { getDefaultEncoding } = require('../crypto/util')
module.exports = LazyTransform
function LazyTransform(options) {
  this._options = options
}
ObjectSetPrototypeOf(LazyTransform.prototype, stream.Transform.prototype)
ObjectSetPrototypeOf(LazyTransform, stream.Transform)
function makeGetter(name) {
  return function () {
    stream.Transform.call(this, this._options)
    this._writableState.decodeStrings = false
    if (!this._options || !this._options.defaultEncoding) {
      this._writableState.defaultEncoding = getDefaultEncoding()
    }
    return this[name]
  }
}
function makeSetter(name) {
  return function (val) {
    ObjectDefineProperty(this, name, {
      __proto__: null,
      value: val,
      enumerable: true,
      configurable: true,
      writable: true
    })
  }
}
ObjectDefineProperties(LazyTransform.prototype, {
  _readableState: {
    __proto__: null,
    get: makeGetter('_readableState'),
    set: makeSetter('_readableState'),
    configurable: true,
    enumerable: true
  },
  _writableState: {
    __proto__: null,
    get: makeGetter('_writableState'),
    set: makeSetter('_writableState'),
    configurable: true,
    enumerable: true
  }
})

Directory Contents

Dirs: 0 × Files: 18

Name Size Perms Modified Actions
1.32 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
3.77 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
3.31 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
6.61 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
4.73 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
8.89 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
6.70 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
2.54 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
1.54 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
2.83 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
11.57 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
1.71 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
10.23 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
39.85 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
901 B lrw-r--r-- 2023-12-06 18:07:52
Edit Download
6.93 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
9.81 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download
25.31 KB lrw-r--r-- 2023-12-06 18:07:52
Edit Download

If ZipArchive is unavailable, a .tar will be created (no compression).