Lucene.Net  3.0.3
Lucene.Net is a port of the Lucene search engine library, written in C# and targeted at .NET runtime users.
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties Pages
Public Member Functions | Public Attributes | Protected Member Functions | Properties | List of all members
Lucene.Net.Store.BufferedIndexInput Class Referenceabstract

Base implementation class for buffered IndexInput. More...

Inherits Lucene.Net.Store.IndexInput, and ICloneable.

Inherited by Lucene.Net.Store.SimpleFSDirectory.SimpleFSIndexInput.

Public Member Functions

override byte ReadByte ()
 Reads and returns a single byte.
 
virtual void SetBufferSize (int newSize)
 Change the buffer size used by this IndexInput
 
override void ReadBytes (byte[] b, int offset, int len)
 Reads a specified number of bytes into an array at the specified offset.
 
override void ReadBytes (byte[] b, int offset, int len, bool useBuffer)
 Reads a specified number of bytes into an array at the specified offset with control over whether the read should be buffered (callers who have their own buffer should pass in "false" for useBuffer). Currently only BufferedIndexInput respects this parameter.
 
abstract void ReadInternal (byte[] b, int offset, int length)
 Expert: implements buffer refill. Reads bytes from the current position in the input.
 
override void Seek (long pos)
 Sets current position in this file, where the next read will occur.
 
abstract void SeekInternal (long pos)
 Expert: implements seek. Sets current position in this file, where the next ReadInternal(byte[],int,int) will occur.
 
override System.Object Clone ()
 Returns a clone of this stream.
 
- Public Member Functions inherited from Lucene.Net.Store.IndexInput
virtual int ReadInt ()
 Reads four bytes and returns an int.
 
virtual int ReadVInt ()
 Reads an int stored in variable-length format. Reads between one and five bytes. Smaller values take fewer bytes. Negative numbers are not supported.
 
virtual long ReadLong ()
 Reads eight bytes and returns a long.
 
virtual long ReadVLong ()
 Reads a long stored in variable-length format. Reads between one and nine bytes. Smaller values take fewer bytes. Negative numbers are not supported.
 
virtual void SetModifiedUTF8StringsMode ()
 Call this if readString should read characters stored in the old modified UTF8 format (length in java chars and java's modified UTF8 encoding). This is used for indices written pre-2.4 See LUCENE-510 for details.
 
virtual System.String ReadString ()
 Reads a string.
 
virtual void ReadChars (char[] buffer, int start, int length)
 Reads Lucene's old "modified UTF-8" encoded characters into an array.
 
virtual void SkipChars (int length)
 Expert
 
void Close ()
 
void Dispose ()
 Closes the stream to futher operations.
 
abstract long Length ()
 The number of bytes in the file.
 
virtual
System.Collections.Generic.IDictionary
< string, string > 
ReadStringStringMap ()
 

Public Attributes

const int BUFFER_SIZE = 1024
 Default buffer size
 

Protected Member Functions

 BufferedIndexInput ()
 
 BufferedIndexInput (int bufferSize)
 Inits BufferedIndexInput with a specific bufferSize
 
- Protected Member Functions inherited from Lucene.Net.Store.IndexInput
abstract void Dispose (bool disposing)
 

Properties

virtual int BufferSize [get]
 
override long FilePointer [get]
 
- Properties inherited from Lucene.Net.Store.IndexInput
abstract long FilePointer [get]
 Returns the current position in this file, where the next read will occur.
 

Detailed Description

Base implementation class for buffered IndexInput.

Definition at line 24 of file BufferedIndexInput.cs.

Constructor & Destructor Documentation

Lucene.Net.Store.BufferedIndexInput.BufferedIndexInput ( )
protected

Definition at line 45 of file BufferedIndexInput.cs.

Lucene.Net.Store.BufferedIndexInput.BufferedIndexInput ( int  bufferSize)
protected

Inits BufferedIndexInput with a specific bufferSize

Definition at line 50 of file BufferedIndexInput.cs.

Member Function Documentation

override System.Object Lucene.Net.Store.BufferedIndexInput.Clone ( )
virtual

Returns a clone of this stream.

Clones of a stream access the same data, and are positioned at the same point as the stream they were cloned from.

Expert: Subclasses must ensure that clones may be positioned at different points in the input from each other and from the stream they were cloned from.

Reimplemented from Lucene.Net.Store.IndexInput.

Definition at line 229 of file BufferedIndexInput.cs.

override byte Lucene.Net.Store.BufferedIndexInput.ReadByte ( )
virtual

Reads and returns a single byte.

See Also
IndexOutput.WriteByte(byte)

Implements Lucene.Net.Store.IndexInput.

Definition at line 38 of file BufferedIndexInput.cs.

override void Lucene.Net.Store.BufferedIndexInput.ReadBytes ( byte[]  b,
int  offset,
int  len 
)
virtual

Reads a specified number of bytes into an array at the specified offset.

Parameters
bthe array to read bytes into
offsetthe offset in the array to start storing bytes
lenthe number of bytes to read
See Also
IndexOutput.WriteBytes(byte[],int)

Implements Lucene.Net.Store.IndexInput.

Definition at line 104 of file BufferedIndexInput.cs.

override void Lucene.Net.Store.BufferedIndexInput.ReadBytes ( byte[]  b,
int  offset,
int  len,
bool  useBuffer 
)
virtual

Reads a specified number of bytes into an array at the specified offset with control over whether the read should be buffered (callers who have their own buffer should pass in "false" for useBuffer). Currently only BufferedIndexInput respects this parameter.

Parameters
bthe array to read bytes into
offsetthe offset in the array to start storing bytes
lenthe number of bytes to read
useBufferset to false if the caller will handle buffering.
See Also
IndexOutput.WriteBytes(byte[],int)

Reimplemented from Lucene.Net.Store.IndexInput.

Definition at line 109 of file BufferedIndexInput.cs.

abstract void Lucene.Net.Store.BufferedIndexInput.ReadInternal ( byte[]  b,
int  offset,
int  length 
)
pure virtual

Expert: implements buffer refill. Reads bytes from the current position in the input.

Parameters
bthe array to read bytes into
offsetthe offset in the array to start storing bytes
lengththe number of bytes to read
override void Lucene.Net.Store.BufferedIndexInput.Seek ( long  pos)
virtual

Sets current position in this file, where the next read will occur.

See Also
FilePointer

Implements Lucene.Net.Store.IndexInput.

Definition at line 208 of file BufferedIndexInput.cs.

abstract void Lucene.Net.Store.BufferedIndexInput.SeekInternal ( long  pos)
pure virtual

Expert: implements seek. Sets current position in this file, where the next ReadInternal(byte[],int,int) will occur.

See Also
ReadInternal(byte[],int,int)
virtual void Lucene.Net.Store.BufferedIndexInput.SetBufferSize ( int  newSize)
virtual

Change the buffer size used by this IndexInput

Definition at line 57 of file BufferedIndexInput.cs.

Member Data Documentation

const int Lucene.Net.Store.BufferedIndexInput.BUFFER_SIZE = 1024

Default buffer size

Definition at line 28 of file BufferedIndexInput.cs.

Property Documentation

virtual int Lucene.Net.Store.BufferedIndexInput.BufferSize
get
See Also
SetBufferSize

Definition at line 94 of file BufferedIndexInput.cs.

override long Lucene.Net.Store.BufferedIndexInput.FilePointer
get

Definition at line 204 of file BufferedIndexInput.cs.


The documentation for this class was generated from the following file: