메소드 | 설명 | |
---|---|---|
Add ( BytesRef bytes ) : int |
Adds a new BytesRef
|
|
AddByPoolOffset ( int offset ) : int |
Adds a "arbitrary" int offset instead of a BytesRef term. this is used in the indexer to hold the hash for term vectors, because they do not redundantly store the byte[] term directly and instead reference the byte[] term already stored by the postings BytesRefHash. See add(int textStart) in TermsHashPerField.
|
|
ByteStart ( int bytesID ) : int |
Returns the bytesStart offset into the internally used ByteBlockPool for the given bytesID
|
|
BytesRefHash ( ) : System |
Creates a new BytesRefHash with a ByteBlockPool using a DirectAllocator.
|
|
BytesRefHash ( Lucene.Net.Util.ByteBlockPool pool ) : System |
Creates a new BytesRefHash
|
|
BytesRefHash ( Lucene.Net.Util.ByteBlockPool pool, int capacity, BytesStartArray bytesStartArray ) : System |
Creates a new BytesRefHash
|
|
Clear ( ) : void | ||
Clear ( bool resetPool ) : void |
Clears the BytesRef which maps to the given BytesRef
|
|
Close ( ) : void |
Closes the BytesRefHash and releases all internally used memory
|
|
Compact ( ) : int[] |
Returns the ids array in arbitrary order. Valid ids start at offset of 0 and end at a limit of #size() - 1 Note: this is a destructive operation. #clear() must be called in order to reuse this BytesRefHash instance.
|
|
Find ( BytesRef bytes ) : int |
Returns the id of the given BytesRef.
|
|
Get ( int bytesID, BytesRef @ref ) : BytesRef |
Populates and returns a BytesRef with the bytes for the given bytesID. Note: the given bytesID must be a positive integer less than the current size (#size())
|
|
Reinit ( ) : void |
reinitializes the BytesRefHash after a previous #clear() call. If #clear() has not been called previously this method has no effect.
|
|
Size ( ) : int |
Returns the number of BytesRef values in this BytesRefHash.
|
|
Sort ( IComparer |
Returns the values array sorted by the referenced byte values. Note: this is a destructive operation. #clear() must be called in order to reuse this BytesRefHash instance.
|
메소드 | 설명 | |
---|---|---|
DoHash ( byte bytes, int offset, int length ) : int | ||
Equals ( int id, BytesRef b ) : bool | ||
FindHash ( BytesRef bytes ) : int | ||
Rehash ( int newSize, bool hashOnData ) : void |
Called when hash is too small (> 50% occupied) or too large (< 20% occupied).
|
|
Shrink ( int targetSize ) : bool |
public BytesRefHash ( Lucene.Net.Util.ByteBlockPool pool ) : System | ||
pool | Lucene.Net.Util.ByteBlockPool | |
리턴 | System |
public BytesRefHash ( Lucene.Net.Util.ByteBlockPool pool, int capacity, BytesStartArray bytesStartArray ) : System | ||
pool | Lucene.Net.Util.ByteBlockPool | |
capacity | int | |
bytesStartArray | BytesStartArray | |
리턴 | System |
public Find ( BytesRef bytes ) : int | ||
bytes | BytesRef | /// the bytes to look for /// |
리턴 | int |
public Get ( int bytesID, BytesRef @ref ) : BytesRef | ||
bytesID | int | /// the id |
@ref | BytesRef | |
리턴 | BytesRef |
public Sort ( IComparer |
||
comp | IComparer |
/// the |
리턴 | int[] |