public abstract class Fields extends Object implements Iterable<String>
Modifier and Type | Field and Description |
---|---|
static Fields[] |
EMPTY_ARRAY
Zero-length
Fields array. |
Modifier | Constructor and Description |
---|---|
protected |
Fields()
Sole constructor.
|
Modifier and Type | Method and Description |
---|---|
long |
getUniqueTermCount()
Deprecated.
iterate fields and add their size() instead.
this method is only provided as a transition mechanism
to access this statistic for 3.x indexes, which do not
have this statistic per-field.
|
abstract Iterator<String> |
iterator()
Returns an iterator that will step through all fields
names.
|
abstract int |
size()
Returns the number of fields or -1 if the number of
distinct field names is unknown.
|
abstract Terms |
terms(String field)
Get the
Terms for this field. |
public static final Fields[] EMPTY_ARRAY
Fields
array.protected Fields()
public abstract Iterator<String> iterator()
public abstract Terms terms(String field) throws IOException
Terms
for this field. This will return
null if the field does not exist.IOException
public abstract int size()
iterator()
will return as many field names.@Deprecated public long getUniqueTermCount() throws IOException
IOException
Terms.size()
Copyright © 2000-2013 Apache Software Foundation. All Rights Reserved.