Class CompoundFileDirectory
Class for accessing a compound stream. This class implements a directory, but is limited to only read operations. Directory methods that would normally modify data throw an exception.
All files belonging to a segment have the same name with varying extensions.
The extensions correspond to the different file formats used by the Codec.
When using the Compound File format these files are collapsed into a
single .cfs
file (except for the LiveDocsFormat, with a
corresponding .cfe
file indexing its sub-files.
Files:
.cfs
: An optional "virtual" file consisting of all the other index files for systems that frequently run out of file handles..cfe
: The "virtual" compound file's entry table holding all entries in the corresponding .cfs file.
Description:
- Compound (.cfs) --> Header, FileData FileCount
- Compound Entry Table (.cfe) --> Header, FileCount, <FileName, DataOffset, DataLength> FileCount, Footer
- Header --> WriteHeader(DataOutput, String, Int32)
- FileCount --> WriteVInt32(Int32)
- DataOffset,DataLength --> WriteInt64(Int64)
- FileName --> WriteString(String)
- FileData --> raw file data
- Footer --> WriteFooter(IndexOutput)
Notes:
- FileCount indicates how many files are contained in this compound file. The entry table that follows has that many entries.
- Each directory entry contains a long pointer to the start of this file's data
section, the files length, and a
with that file's name.
@lucene.experimental
Inherited Members
Assembly: DistributedLucene.Net.dll
Syntax
public sealed class CompoundFileDirectory : BaseDirectory
Constructors
Name | Description |
---|---|
CompoundFileDirectory(Directory, String, IOContext, Boolean) | Create a new CompoundFileDirectory. |
Properties
Name | Description |
---|---|
Directory | |
Name |
Methods
Name | Description |
---|---|
CreateOutput(String, IOContext) | |
CreateSlicer(String, IOContext) | |
DeleteFile(String) | Not implemented |
Dispose(Boolean) | |
FileExists(String) | Returns true iff a file with the given name exists. |
FileLength(String) | Returns the length of a file in the directory. |
ListAll() | Returns an array of strings, one for each file in the directory. |
MakeLock(String) | Not implemented |
OpenInput(String, IOContext) | |
RenameFile(String, String) | Not implemented |
Sync(ICollection<String>) | |
ToString() |