public interface Question<ANSWER>
| Modifier and Type | Method and Description |
|---|---|
static QuestionBuilder |
about(String subject) |
ANSWER |
answeredBy(Actor actor) |
default Question<ANSWER> |
as(Class<ANSWER> type) |
default Question<LocalDate> |
asADate() |
default Question<LocalDate> |
asADate(String format) |
default Question<BigDecimal> |
asBigDecimal() |
default Question<Boolean> |
asBoolean() |
default Question<Double> |
asDouble() |
default <T> Question<T> |
asEnum(Class<T> enumType) |
default Question<Float> |
asFloat() |
default Question<Integer> |
asInteger() |
default <T> Question<List<T>> |
asListOf(Class<T> type) |
default Question<Long> |
asLong() |
default Question<String> |
asString() |
default Question<ANSWER> |
describedAs(String description)
Returns a new question with the specified text as a subject.
|
default String |
getSubject() |
default <T> Question<T> |
map(Function<ANSWER,T> transformer)
Convert the answer to a question into another form using an arbitrary function.
|
default <T> Question<List<T>> |
mapEach(Function<String,T> transformer) |
static Question<Boolean> |
not(Question<Boolean> question) |
default String getSubject()
static QuestionBuilder about(String subject)
default Question<BigDecimal> asBigDecimal()
default <T> Question<T> map(Function<ANSWER,T> transformer)
T - transformer - default Question<ANSWER> describedAs(String description)
description - Copyright © 2021. All rights reserved.