Package org.apache.fop.pdf
Class StreamCacheFactory
java.lang.Object
org.apache.fop.pdf.StreamCacheFactory
This class is serves as a factory from
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGet the correct implementation (based on cacheToFile) of StreamCache.createStreamCache
(int hintSize) Get the correct implementation (based on cacheToFile) of StreamCache.static StreamCacheFactory
Returns an instance of a StreamCacheFactory with the requested features.
-
Field Details
-
memoryInstance
-
-
Constructor Details
-
StreamCacheFactory
private StreamCacheFactory()Creates a new StreamCacheFactory.- Parameters:
cacheToFile
- True if file shall be cached using a temporary file
-
-
Method Details
-
getInstance
Returns an instance of a StreamCacheFactory with the requested features.- Returns:
- StreamCacheFactory the requested factory
-
createStreamCache
Get the correct implementation (based on cacheToFile) of StreamCache.- Returns:
- a new StreamCache for caching streams
- Throws:
IOException
- if there is an IO error
-
createStreamCache
Get the correct implementation (based on cacheToFile) of StreamCache.- Parameters:
hintSize
- a hint about the approximate expected size of the buffer- Returns:
- a new StreamCache for caching streams
- Throws:
IOException
- if there is an IO error
-