public class BasicCollectionWriter extends Object implements CollectionWriter
Writing collection to disk
Copyright: Copyright (c) 2005
Company: IST, Drexel University
| Modifier and Type | Field and Description |
|---|---|
protected BasicArticleIndex |
articleIndex |
protected String |
charSet |
protected ArticleParser |
parser |
protected RandomAccessFile |
rafCollection |
| Constructor and Description |
|---|
BasicCollectionWriter(String collectionFile,
String indexFile,
boolean append) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
add(Article article)
Adds an article to the collection
|
void |
close()
Closes the collection writer and releases all resources.
|
ArticleParser |
getArticleParser()
Gets the article parser of the collection writer
|
void |
setArticleParser(ArticleParser parser)
Sets the article parser for the collection writer
|
protected RandomAccessFile rafCollection
protected BasicArticleIndex articleIndex
protected ArticleParser parser
protected String charSet
public ArticleParser getArticleParser()
CollectionWritergetArticleParser in interface CollectionWriterpublic void setArticleParser(ArticleParser parser)
CollectionWritersetArticleParser in interface CollectionWriterparser - the article parserpublic boolean add(Article article)
CollectionWriteradd in interface CollectionWriterarticle - an articlepublic void close()
CollectionWriterclose in interface CollectionWriterCopyright © 2018 JULIE Lab, Germany. All rights reserved.