public interface IResultSet extends List<IResult>, IStatus, IPresentation
| Modifier and Type | Field and Description |
|---|---|
static String |
FEATURE_ERROR_MAX_SIZE
Feature for limit quantity of errors in toString().
|
static String |
FEATURE_EXPECTED_CRITERIA
Feature for messages criteria.
|
static String |
FEATURE_EXPECTED_MESSAGES
Feature for expected messages.
|
static String |
FEATURE_EXPECTED_SORTED
Feature for messages expectation order.
|
static String |
FEATURE_FULL_TRACE
Feature for full trace on results.
|
static String |
FEATURE_RECORD_SUCCESS
Feature for disable success recording.
|
static String |
FEATURE_RESULT_FILTER
Feature for result filter.
|
| Modifier and Type | Method and Description |
|---|---|
List<ActionType> |
actionTypes()
List action types available for all results.
|
List<ActionType> |
actionTypes(List<IResult> subset)
List action types available for the result subset.
|
IResult |
addResult(Status status,
IBlock source)
Add a result.
|
IResult |
addResult(Status status,
IBlock source,
IWritable writable)
Adds a result.
|
IResult |
addResult(Status status,
IBlock source,
String message)
Adds a result with a message.
|
IResult |
addResult(Status status,
IBlock source,
String message,
IWritable writable)
Adds a result with a message and a writable information.
|
IResult |
addResult(Status status,
IBlock source,
Throwable failure)
Adds a result with failure information.
|
IResult |
addResult(Status status,
IBlock source,
Throwable failure,
IWritable writable)
Adds a result with failure and a writable information.
|
<T extends Status> |
availableStatus()
Lists status in result.
|
void |
consolidate(IContext context)
Consolidate expectations and received errors.
|
int |
countErrors()
Return number of errors.
|
int |
countErrors(int start)
Return number of errors.
|
<T extends Status> |
countStatus(int start,
int end,
T... status)
Counts the status of a given type.
|
<T extends Status> |
countStatus(List<IResult> subset,
T... status)
Counts the status of a given type.
|
<T extends Status> |
countStatus(T... status)
Counts the status of a given type.
|
int |
countType(ActionType... actionType)
Count results of a given set of action types.
|
int |
countType(List<IResult> subset,
ActionType... actionType)
Count results of a given type in a list.
|
<T extends Status> |
errorStatus()
Lists error status in result.
|
<T extends Status> |
filterByStatus(int start,
int end,
T... status)
Filters result by status type.
|
<T extends Status> |
filterByStatus(List<IResult> subset,
T... status)
Filters result by status type.
|
<T extends Status> |
filterByStatus(T... status)
Filters result by status type.
|
List<IResult> |
filterByType(ActionType... actionType)
Filter the result itself by
ActionType. |
List<IResult> |
filterByType(List<IResult> subset,
ActionType... actionType)
Filter the subset by
ActionType. |
IStringTest |
getCriteria()
String comparison criteria for messages.
|
Integer |
getErrorMaxSize()
Set max size of error list in toString()
|
Boolean |
getFullTrace()
Get full trace status.
|
String[] |
getMessages()
Get the expected messages.
|
Boolean |
getRecordSuccess()
Flag to record status which
isError returns true. |
IResultFilter |
getResultFilter()
Return the filter.
|
Boolean |
getSorted()
Get the sort flag.
|
void |
setCriteria(IStringTest criteria)
Set a string comparison criteria for messages.
|
void |
setErrorMaxSize(Integer size)
Set max quantity of erros in toString().
|
void |
setFullTrace(Boolean fullTrace)
Set full trace on results dump.
|
void |
setMessages(String[] expected)
Set expected messages.
|
void |
setRecordSuccess(Boolean recordSuccess)
Setting to record success action in result set.
|
void |
setResultFilter(IResultFilter resultFilter)
Set result filter.
|
void |
setSorted(Boolean sorted)
Set expected order of messages.
|
IResultSet |
subSet(int start,
int end)
Get a subset of result as a result set itself.
|
add, add, addAll, addAll, clear, contains, containsAll, equals, get, hashCode, indexOf, isEmpty, iterator, lastIndexOf, listIterator, listIterator, remove, remove, removeAll, retainAll, set, size, subList, toArray, toArrayasNode, asStringstatic final String FEATURE_FULL_TRACE
static final String FEATURE_ERROR_MAX_SIZE
static final String FEATURE_RESULT_FILTER
static final String FEATURE_RECORD_SUCCESS
static final String FEATURE_EXPECTED_MESSAGES
static final String FEATURE_EXPECTED_SORTED
static final String FEATURE_EXPECTED_CRITERIA
void setFullTrace(Boolean fullTrace)
fullTrace - true, to show full trace, false, otherwise. Default is 'true'.Boolean getFullTrace()
void setErrorMaxSize(Integer size)
fullTrace - true, to show full trace, false, otherwise. Default is
'Integer.MAX'.Integer getErrorMaxSize()
void setResultFilter(IResultFilter resultFilter)
resultFilter - A filter.IResultFilter getResultFilter()
void setRecordSuccess(Boolean recordSuccess)
recordSuccess - The record success.Boolean getRecordSuccess()
isError returns true. Default is
true.void setMessages(String[] expected)
expected - Expected messages.String[] getMessages()
void setSorted(Boolean sorted)
sorted - true, if expected messages must obey the specification order,
false, otherwise. Default might be false.Boolean getSorted()
IStringTest getCriteria()
void setCriteria(IStringTest criteria)
criteria - A criteria.void consolidate(IContext context)
context - The context.<T extends Status> List<T> availableStatus()
T - A subclass of Status.<T extends Status> List<T> errorStatus()
T - A subclass of Status.<T extends Status> List<IResult> filterByStatus(T... status)
T - A subclass of Status.status - The filters.<T extends Status> List<IResult> filterByStatus(int start, int end, T... status)
T - A subtype of Status.start - Range start.end - Range end.status - The filters.<T extends Status> List<IResult> filterByStatus(List<IResult> subset, T... status)
T - A subtype of Status.subset - Subset list.status - The filters.int countErrors()
int countErrors(int start)
start - Start index.<T extends Status> int countStatus(T... status)
T - A subtype of Status.status - The filters.<T extends Status> int countStatus(int start, int end, T... status)
T - A status class.start - Range start.end - Range end.status - The filters.<T extends Status> int countStatus(List<IResult> subset, T... status)
T - A status class.subset - A subset list.status - The filters.List<ActionType> actionTypes()
List<ActionType> actionTypes(List<IResult> subset)
subset - Subset to be analyzed.List<IResult> filterByType(ActionType... actionType)
ActionType.actionType - The action types.List<IResult> filterByType(List<IResult> subset, ActionType... actionType)
ActionType.subset - The subset to be filtered.actionType - The action types.int countType(ActionType... actionType)
actionType - The action types.int countType(List<IResult> subset, ActionType... actionType)
subset - A subset of results.actionType - The action types.IResult addResult(Status status, IBlock source)
status - The status.source - The source block.IResult addResult(Status status, IBlock source, IWritable writable)
status - The status.source - The source block.writable - A writable information.IResult addResult(Status status, IBlock source, String message)
status - The status.source - The source block.message - The message.IResult addResult(Status status, IBlock source, String message, IWritable writable)
status - The status.source - The source block.message - The message.writable - The extra information.IResult addResult(Status status, IBlock source, Throwable failure)
status - The status.source - The source block.failure - The failure.IResult addResult(Status status, IBlock source, Throwable failure, IWritable writable)
status - The status.source - The source block.failure - The failure.writable - The extra information.IResultSet subSet(int start, int end)
start - The start index.end - The end index.Copyright © 2016. All rights reserved.