Class Invocation.Builder
java.lang.Object
com.github.thought2code.mcp.annotated.reflect.Invocation.Builder
- Enclosing class:
- Invocation
This class implements the builder pattern for creating a new instance of
InvocationResult.- Author:
- codeboyzhou
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
result
Sets the result of the invocation.- Parameters:
result- the result of the invocation- Returns:
- the builder instance
-
isError
Sets whether an exception occurred during the invocation.- Parameters:
isError-trueif an exception occurred,falseotherwise- Returns:
- the builder instance
-
build
Builds a new instance ofInvocationResultwith the configured values.- Returns:
- a new instance of
InvocationResult
-