-
Notifications
You must be signed in to change notification settings - Fork 9.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add an abstract base-class, which all the various Stream implementations inherit from #13303
Commits on Apr 28, 2021
-
Configuration menu - View commit details
-
Copy full SHA for 6c1a321 - Browse repository at this point
Copy the full SHA 6c1a321View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1f9b134 - Browse repository at this point
Copy the full SHA 1f9b134View commit details -
Configuration menu - View commit details
-
Copy full SHA for 1f0685c - Browse repository at this point
Copy the full SHA 1f0685cView commit details -
Configuration menu - View commit details
-
Copy full SHA for 342b0c1 - Browse repository at this point
Copy the full SHA 342b0c1View commit details -
Configuration menu - View commit details
-
Copy full SHA for 66b898e - Browse repository at this point
Copy the full SHA 66b898eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 704514c - Browse repository at this point
Copy the full SHA 704514cView commit details -
Configuration menu - View commit details
-
Copy full SHA for d63df04 - Browse repository at this point
Copy the full SHA d63df04View commit details -
Configuration menu - View commit details
-
Copy full SHA for 59591f8 - Browse repository at this point
Copy the full SHA 59591f8View commit details -
Configuration menu - View commit details
-
Copy full SHA for d2227a7 - Browse repository at this point
Copy the full SHA d2227a7View commit details -
Configuration menu - View commit details
-
Copy full SHA for 3294d4d - Browse repository at this point
Copy the full SHA 3294d4dView commit details -
Configuration menu - View commit details
-
Copy full SHA for f6c7a65 - Browse repository at this point
Copy the full SHA f6c7a65View commit details -
Configuration menu - View commit details
-
Copy full SHA for cdb583b - Browse repository at this point
Copy the full SHA cdb583bView commit details -
Configuration menu - View commit details
-
Copy full SHA for 28b0809 - Browse repository at this point
Copy the full SHA 28b0809View commit details -
Configuration menu - View commit details
-
Copy full SHA for a9476e7 - Browse repository at this point
Copy the full SHA a9476e7View commit details -
Configuration menu - View commit details
-
Copy full SHA for e938c05 - Browse repository at this point
Copy the full SHA e938c05View commit details -
Configuration menu - View commit details
-
Copy full SHA for 66d9d83 - Browse repository at this point
Copy the full SHA 66d9d83View commit details -
Configuration menu - View commit details
-
Copy full SHA for b08f9a8 - Browse repository at this point
Copy the full SHA b08f9a8View commit details -
Configuration menu - View commit details
-
Copy full SHA for 40c342e - Browse repository at this point
Copy the full SHA 40c342eView commit details -
Configuration menu - View commit details
-
Copy full SHA for 1e5bf35 - Browse repository at this point
Copy the full SHA 1e5bf35View commit details -
Configuration menu - View commit details
-
Copy full SHA for aa1deaf - Browse repository at this point
Copy the full SHA aa1deafView commit details -
Configuration menu - View commit details
-
Copy full SHA for 213e1c3 - Browse repository at this point
Copy the full SHA 213e1c3View commit details -
Move the
DecodeStream
andStreamsSequenceStream
from `src/core/st……ream.js` and into its own file
Configuration menu - View commit details
-
Copy full SHA for 30a22a1 - Browse repository at this point
Copy the full SHA 30a22a1View commit details -
Configuration menu - View commit details
-
Copy full SHA for 8ce2cae - Browse repository at this point
Copy the full SHA 8ce2caeView commit details -
Configuration menu - View commit details
-
Copy full SHA for b11f012 - Browse repository at this point
Copy the full SHA b11f012View commit details -
Configuration menu - View commit details
-
Copy full SHA for 29cf415 - Browse repository at this point
Copy the full SHA 29cf415View commit details -
Configuration menu - View commit details
-
Copy full SHA for 6151b4e - Browse repository at this point
Copy the full SHA 6151b4eView commit details -
Add an abstract base-class, which all the various Stream implementati…
…ons inherit from By having an abstract base-class, it becomes a lot clearer exactly which methods/getters are expected to exist on all Stream instances. Furthermore, since a number of the methods are *identical* for all Stream implementations, this reduces unnecessary code duplication in the `Stream`, `DecodeStream`, and `ChunkedStream` classes. For e.g. `gulp mozcentral`, the *built* `pdf.worker.js` files decreases from `1 619 329` to `1 616 115` bytes with this patch-series.
Configuration menu - View commit details
-
Copy full SHA for 67415bf - Browse repository at this point
Copy the full SHA 67415bfView commit details -
Improve the handling
getBaseStreams
, on the various Stream implemen……tations The way that `getBaseStreams` is currently handled has bothered me from time to time, especially how we're checking if the method exists before calling it. By adding a dummy `BaseStream.getBaseStreams` method, and having the call-sites simply check the return value, we can improve some of the relevant code. Note in particular how the `ObjectLoader._walk` method didn't actually check that the data in question is a Stream instance, and instead only checked the `currentNode` (which could be anything) for the existence of a `getBaseStreams` property.
Configuration menu - View commit details
-
Copy full SHA for 67a1cfc - Browse repository at this point
Copy the full SHA 67a1cfcView commit details -
Stop special-casing the
dict
parameter in theJbig2Stream
/`JpegSt……ream`/`JpxStream` constructors For all of the other `DecodeStream`s we're not passing in a `Dict`-instance manually, but instead get it from the `stream`-parameter. Hence there's no particularly good reason, as far as I can tell, to not do the same thing in `Jbig2Stream`/`JpegStream`/`JpxStream` as well.
Configuration menu - View commit details
-
Copy full SHA for fb07755 - Browse repository at this point
Copy the full SHA fb07755View commit details -
Let
ChunkedStream
extendStream
, rather thanBaseStream
directlyLooking at the `ChunkedStream` implementation, it's basically a "regular" `Stream` but with added functionality in order to deal with fetching/loading of missing data. Hence, by letting `ChunkedStream` extend `Stream`, we can remove some duplicate methods from the `ChunkedStream` class.
Configuration menu - View commit details
-
Copy full SHA for 2ac4ad3 - Browse repository at this point
Copy the full SHA 2ac4ad3View commit details