|
ModeShape Distribution 3.5.0.Final | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.modeshape.jcr.BackupDocumentWriter
@NotThreadSafe public final class BackupDocumentWriter
A utility that writes Document instances to one or more sequential files in a backup directory.
| Field Summary | |
|---|---|
protected long |
count
|
static String |
DOCUMENTS_EXTENSION
|
protected long |
fileCount
|
static String |
GZIP_EXTENSION
|
protected long |
maxDocumentsPerFile
|
protected OutputStream |
stream
|
protected long |
totalCount
|
| Constructor Summary | |
|---|---|
BackupDocumentWriter(File parentDirectory,
String filenamePrefix,
long documentsPerFile,
boolean compress,
Problems problems)
|
|
| Method Summary | |
|---|---|
void |
close()
Close this writer, which flushes and closes any currently-open streams. |
long |
getDocumentCount()
Return the number of documents that have been written so far. |
long |
getFileCount()
Return the number of files that have been written so far. |
void |
write(Document document)
Append the supplied document to the files. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final String GZIP_EXTENSION
public static final String DOCUMENTS_EXTENSION
protected final long maxDocumentsPerFile
protected OutputStream stream
protected long count
protected long totalCount
protected long fileCount
| Constructor Detail |
|---|
public BackupDocumentWriter(File parentDirectory,
String filenamePrefix,
long documentsPerFile,
boolean compress,
Problems problems)
| Method Detail |
|---|
public void write(Document document)
document - the document to be written; may not be nullpublic void close()
public long getDocumentCount()
public long getFileCount()
|
ModeShape Distribution 3.5.0.Final | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||