Package org.jbehave.core.model
Class OutcomesTable
- java.lang.Object
-
- org.jbehave.core.model.OutcomesTable
-
public class OutcomesTable extends Object
Represents a tabular structure that holdsOutcomesTable.Outcomes to be verified by invoking methodverify(). If verification fails anOutcomesTable.OutcomesFailedexception is thrown.The Outcomes Tables allows the specification of
Keywordsfor the outcome fields, as well as rendering formats for different types. The default formats include:- Date: "EEE MMM dd hh:mm:ss zzz yyyy"
- Number: "0.###"
- Boolean: "yes,no"
getFormat(Type)andgetFormat(String).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classOutcomesTable.FormatTypeInvalidstatic classOutcomesTable.Outcome<T>static classOutcomesTable.OutcomesFailed
-
Constructor Summary
Constructors Constructor Description OutcomesTable()OutcomesTable(Map<Type,String> formats)OutcomesTable(Keywords keywords)OutcomesTable(Keywords keywords, String dateFormat)Deprecated.OutcomesTable(Keywords keywords, Map<Type,String> formats)
-
Method Summary
Modifier and Type Method Description <T> voidaddOutcome(String description, T value, org.hamcrest.Matcher<T> matcher)StringasString()UUIDExceptionWrapperfailureCause()StringgetDateFormat()Deprecated.UsegetFormat(Type)List<OutcomesTable.Outcome<?>>getFailedOutcomes()StringgetFormat(Type type)StringgetFormat(String typeName)Map<Type,String>getFormats()List<String>getOutcomeFields()List<OutcomesTable.Outcome<?>>getOutcomes()StringtoString()voidverify()
-
-
-
Constructor Detail
-
OutcomesTable
public OutcomesTable()
-
OutcomesTable
public OutcomesTable(Keywords keywords)
-
OutcomesTable
@Deprecated public OutcomesTable(Keywords keywords, String dateFormat)
Deprecated.Creates outcomes table using the specified keywords and date format
-
-
Method Detail
-
addOutcome
public <T> void addOutcome(String description, T value, org.hamcrest.Matcher<T> matcher)
-
verify
public void verify()
-
failureCause
public UUIDExceptionWrapper failureCause()
-
getOutcomes
public List<OutcomesTable.Outcome<?>> getOutcomes()
-
getFailedOutcomes
public List<OutcomesTable.Outcome<?>> getFailedOutcomes()
-
getDateFormat
@Deprecated public String getDateFormat()
Deprecated.UsegetFormat(Type)Provides used date format
-
asString
public String asString()
-
-