Package stroom.query.api.v2
Class Result.Builder<T extends Result,CHILD_CLASS extends Result.Builder<T,?>>
- java.lang.Object
-
- stroom.query.api.v2.Result.Builder<T,CHILD_CLASS>
-
- Type Parameters:
T
- The result class type, either Flat or TableCHILD_CLASS
- The subclass, allowing us to template OwnedBuilder correctly
- Direct Known Subclasses:
FlatResult.Builder
,TableResult.Builder
- Enclosing class:
- Result
public abstract static class Result.Builder<T extends Result,CHILD_CLASS extends Result.Builder<T,?>> extends java.lang.Object
Builder for constructing aResult
. This class is abstract and must be overridden for each known Result implementation class.
-
-
Constructor Summary
Constructors Constructor Description Builder()
-
Method Summary
Modifier and Type Method Description abstract T
build()
CHILD_CLASS
componentId(java.lang.String value)
CHILD_CLASS
error(java.lang.String value)
protected java.lang.String
getComponentId()
protected java.lang.String
getError()
protected abstract CHILD_CLASS
self()
-
-
-
Method Detail
-
componentId
public CHILD_CLASS componentId(java.lang.String value)
- Parameters:
value
- The ID of the component that this result set was requested for. See ResultRequest in SearchRequest- Returns:
- The
Result.Builder
, enabling method chaining
-
error
public CHILD_CLASS error(java.lang.String value)
- Parameters:
value
- If an error has occurred producing this result set then this will have details- Returns:
- The
Result.Builder
, enabling method chaining
-
getComponentId
protected java.lang.String getComponentId()
-
getError
protected java.lang.String getError()
-
self
protected abstract CHILD_CLASS self()
-
build
public abstract T build()
-
-