(data, inputEncoding, outputEncoding)
| 151 | }; |
| 152 | |
| 153 | function update(data, inputEncoding, outputEncoding) { |
| 154 | if (typeof data === 'string') { |
| 155 | validateEncoding(data, inputEncoding); |
| 156 | } else if (!isArrayBufferView(data)) { |
| 157 | throw new ERR_INVALID_ARG_TYPE( |
| 158 | 'data', ['string', 'Buffer', 'TypedArray', 'DataView'], data); |
| 159 | } |
| 160 | |
| 161 | const ret = this[kHandle].update(data, inputEncoding); |
| 162 | |
| 163 | if (outputEncoding && outputEncoding !== 'buffer') { |
| 164 | this._decoder = getDecoder(this._decoder, outputEncoding); |
| 165 | return this._decoder.write(ret); |
| 166 | } |
| 167 | |
| 168 | return ret; |
| 169 | }; |
| 170 | |
| 171 | function final(outputEncoding) { |
| 172 | const ret = this[kHandle].final(); |
nothing calls this directly
no test coverage detected
searching dependent graphs…