| Modifier and Type | Field and Description |
|---|---|
static int |
CF_ACCEPTED
This authority value has been confirmed as accurate by an
interactive user or authoritative policy
|
static int |
CF_AMBIGUOUS
There are multiple matching authority values of equal validity.
|
static int |
CF_FAILED
The authority encountered an internal failure - this preserves a
record in the metadata of why there is no value.
|
static int |
CF_NOTFOUND
There are no matching answers from the authority.
|
static int |
CF_NOVALUE
No reasonable confidence value is available
|
static int |
CF_REJECTED
The authority recommends this submission be rejected.
|
static int |
CF_UNCERTAIN
Value is singular and valid but has not been seen and accepted
by a human, so its provenance is uncertain.
|
static int |
CF_UNSET
Value has not been set (DB default).
|
int |
confidence
The confidence level that applies to all values in this result set
|
int |
defaultSelected
Index of value to be selected by default, if any.
|
boolean |
more
true when there are more values to be sent after this result.
|
int |
start
Index of start of this result wrt.
|
int |
total
Count of total results available
|
Choice[] |
values
The set of values returned by the authority
|
| Constructor and Description |
|---|
Choices(boolean isError)
Constructor for simple empty or error results
|
Choices(Choice[] values,
int start,
int total,
int confidence,
boolean more)
Constructor for general purpose
|
Choices(Choice[] values,
int start,
int total,
int confidence,
boolean more,
int defaultSelected)
Constructor for general purpose
|
Choices(int confidence)
Constructor for error results
|
| Modifier and Type | Method and Description |
|---|---|
static String |
getConfidenceText(int cv)
Get the symbolic name corresponding to a confidence value, or CF_NOVALUE's
name if the value is unknown.
|
static int |
getConfidenceValue(String ct)
Get the value corresponding to a symbolic name of a confidence
value, or CF_NOVALUE if the symbol is unknown.
|
static int |
getConfidenceValue(String ct,
int dflt)
Get the value corresponding to a symbolic name of a confidence
value, or the given default if the symbol is unknown.
|
boolean |
isError()
Predicate, did this result encounter an error?
|
public static final int CF_ACCEPTED
public static final int CF_UNCERTAIN
public static final int CF_AMBIGUOUS
public static final int CF_NOTFOUND
public static final int CF_FAILED
public static final int CF_REJECTED
public static final int CF_NOVALUE
public static final int CF_UNSET
public Choice[] values
public int confidence
public int start
public int total
public int defaultSelected
public boolean more
public Choices(Choice[] values, int start, int total, int confidence, boolean more)
public Choices(Choice[] values, int start, int total, int confidence, boolean more, int defaultSelected)
public Choices(int confidence)
public Choices(boolean isError)
public boolean isError()
public static String getConfidenceText(int cv)
cv - confidence valuepublic static int getConfidenceValue(String ct)
ct - symbolic name in Stringpublic static int getConfidenceValue(String ct, int dflt)
ct - symbolic name in Stringdflt - the default value to returnCopyright © 2016 DuraSpace. All Rights Reserved.