|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectewe.database.EntrySelector
| Field Summary | |
int[] |
criteria
|
Database |
db
|
DatabaseEntry |
de
|
boolean |
forceAFilterSearch
|
boolean |
hasWildCards
|
| Constructor Summary | |
EntrySelector(Database db,
Object searchData,
int[] criteria,
boolean hasWildCards)
|
|
EntrySelector(Database db,
Object primarySearchFields,
int sortID,
boolean hasWildCards)
|
|
EntrySelector(Database db,
Object searchData,
int sortID,
int numberOfCriteria,
boolean hasWildCards)
|
|
EntrySelector(FoundEntries fe,
Object primarySearchFields,
boolean hasWildCards)
|
|
EntrySelector(FoundEntries fe,
Object searchData,
int numberOfCriteria,
boolean hasWildCards)
|
|
| Method Summary | |
boolean |
canSearch(FoundEntries fe)
Return if the specified FoundEntries is sorted by a search criteria that is compatible with this EntrySelector, such that a binary-chop search is possible using this EntrySelector on the specified FoundEntries. |
boolean |
canSearch(int sortID)
Return if the specified sort ID for the EntrySelector's Database is compatible with this EntrySelector, such that a binary-chop search is possible using this EntrySelector on the database. |
boolean |
canSearch(int[] sortCriteria)
Return if the specified sort criteria is compatible with this EntrySelector, such that a binary-chop search is possible using this EntrySelector on the database. |
int |
compare(Object dataOrEntry)
|
int |
decode(Database db,
byte[] source,
int offset,
DataProcessor decryptor)
Decode the EntrySelector for use with the specified Database. |
protected int |
doCompare(DatabaseEntry myData,
DatabaseEntry other)
|
ByteArray |
encode(ByteArray destination,
DataProcessor encryptor)
Encode and append the EntrySelector to a ByteArray. |
int[] |
getCriteria()
|
Comparer |
toComparer()
|
ObjectFinder |
toObjectFinder()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, toString |
| Field Detail |
public DatabaseEntry de
public Database db
public int[] criteria
public boolean hasWildCards
public boolean forceAFilterSearch
| Constructor Detail |
public EntrySelector(Database db,
Object primarySearchFields,
int sortID,
boolean hasWildCards)
public EntrySelector(FoundEntries fe,
Object primarySearchFields,
boolean hasWildCards)
public EntrySelector(FoundEntries fe,
Object searchData,
int numberOfCriteria,
boolean hasWildCards)
public EntrySelector(Database db,
Object searchData,
int[] criteria,
boolean hasWildCards)
public EntrySelector(Database db,
Object searchData,
int sortID,
int numberOfCriteria,
boolean hasWildCards)
throws IllegalArgumentException
| Method Detail |
public int[] getCriteria()
public ByteArray encode(ByteArray destination,
DataProcessor encryptor)
throws IOException
destination - the destination ByteArray. If this is null a new one will be created.encryptor - an optional encryptor for the field search data.
IOException - if there was an error encrypting the data.
public int decode(Database db,
byte[] source,
int offset,
DataProcessor decryptor)
throws IOException
db - The Database this comparer will be used with.source - The encoded bytes.offset - The offset in the array of the bytes.decryptor - An optional decryptor to decrypt the data.
IOException - if there is an error decyrpting the data.public boolean canSearch(FoundEntries fe)
public boolean canSearch(int[] sortCriteria)
public boolean canSearch(int sortID)
throws IllegalArgumentException
IllegalArgumentException
protected int doCompare(DatabaseEntry myData,
DatabaseEntry other)
public int compare(Object dataOrEntry)
throws IllegalArgumentException
IllegalArgumentExceptionpublic ObjectFinder toObjectFinder()
public Comparer toComparer()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||