Class RtfEfficientMemoryCache
- java.lang.Object
-
- com.lowagie.text.rtf.document.output.RtfEfficientMemoryCache
-
- All Implemented Interfaces:
RtfDataCache
public class RtfEfficientMemoryCache extends java.lang.Object implements RtfDataCache
The RtfEfficientMemoryCache is an RtfDataCache that keeps the whole rtf document data in memory. More efficient thanRtfMemoryCache
.- Version:
- $Id: RtfEfficientMemoryCache.java 3255 2008-04-14 18:33:30Z xlv $
-
-
Field Summary
Fields Modifier and Type Field Description private RtfByteArrayBuffer
bab
The buffer for the rtf document data.-
Fields inherited from interface com.lowagie.text.rtf.document.output.RtfDataCache
CACHE_DISK, CACHE_MEMORY, CACHE_MEMORY_EFFICIENT
-
-
Constructor Summary
Constructors Constructor Description RtfEfficientMemoryCache()
Constructs a RtfMemoryCache.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.io.OutputStream
getOutputStream()
Gets the OutputStream.void
writeTo(java.io.OutputStream target)
Writes the content of the buffer into the OutputStream.
-
-
-
Field Detail
-
bab
private final RtfByteArrayBuffer bab
The buffer for the rtf document data.
-
-
Method Detail
-
getOutputStream
public java.io.OutputStream getOutputStream()
Gets the OutputStream.- Specified by:
getOutputStream
in interfaceRtfDataCache
- Returns:
- The OutputStream the RtfDocument can use.
-
writeTo
public void writeTo(java.io.OutputStream target) throws java.io.IOException
Writes the content of the buffer into the OutputStream.- Specified by:
writeTo
in interfaceRtfDataCache
- Parameters:
target
- The OutputStream to write the content into.- Throws:
java.io.IOException
- If an error occurs reading/writing.
-
-