public class MockAction extends Action<MockAction>
Rule.RuleMatcher| Modifier and Type | Field and Description |
|---|---|
protected boolean |
cancelRequest |
protected io.inversion.json.JSNode |
json |
protected java.lang.String |
jsonUrl |
protected java.lang.String |
status |
protected int |
statusCode |
ALL_METHODS, configMap, description, excludeMatchers, excludeOn, includeMatchers, includeOn, log, name, order, params| Constructor and Description |
|---|
MockAction() |
MockAction(io.inversion.json.JSNode json) |
MockAction(java.lang.String name) |
MockAction(java.lang.String status,
io.inversion.json.JSNode json) |
MockAction(java.lang.String ruleMatcherSpec,
java.lang.String name,
io.inversion.json.JSNode json) |
| Modifier and Type | Method and Description |
|---|---|
io.inversion.json.JSNode |
getJson() |
java.lang.String |
getJsonUrl() |
java.lang.String |
getStatus() |
int |
getStatusCode() |
boolean |
isCancelRequest() |
void |
run(Request req,
Response res)
Override this method with your custom business logic or override one of the
http method "doMETHOD" specific handlers.
|
MockAction |
wihtStatusCode(int statusCode) |
MockAction |
withCancelRequest(boolean cancelRequest) |
MockAction |
withJson(io.inversion.json.JSNode json) |
MockAction |
withJsonUrl(java.lang.String jsonUrl) |
MockAction |
withStatus(java.lang.String status) |
configureOp, doDelete, doGet, doPatch, doPost, doPut, getFullIncludePaths, getIncludePaths, isDecoration, joinPaths, joinPaths0, run0, withDecorationafterWiringComplete, checkLazyConfig, compareTo, doLazyConfig, getAllExcludePaths, getAllIncludeMethods, getAllIncludePaths, getDefaultIncludeMatchers, getDescription, getExcludeMatchers, getIncludeMatchers, getName, getOrder, getParams, match, match, matches, matches, toString, withDescription, withExcludeOn, withExcludeOn, withIncludeOn, withIncludeOn, withName, withOrder, withParam, withParamsclone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitaddResponse, addResponse, beautifyTag, buildOperation, documentOpDelete, documentOperationSchema, documentOpFind, documentOpGet, documentOpPatch, documentOpPost, documentOpPut, documentOpRelated, documentParam, documentQueryParams, documentRequestSchema, documentResourceSchema, documentResponseSchema, findOp, getDescription, getSchemaRef, hasParam, hook_documentOp, newComponentRefSchema, newHrefSchema, newTypeSchema, removeReadOnlyPropertiesprotected io.inversion.json.JSNode json
protected java.lang.String jsonUrl
protected int statusCode
protected java.lang.String status
protected boolean cancelRequest
public MockAction()
public MockAction(io.inversion.json.JSNode json)
public MockAction(java.lang.String status,
io.inversion.json.JSNode json)
public MockAction(java.lang.String name)
public MockAction(java.lang.String ruleMatcherSpec,
java.lang.String name,
io.inversion.json.JSNode json)
public void run(Request req, Response res) throws ApiException
Actionrun in class Action<MockAction>req - the Request being servicedres - the Reponse being generatedApiExceptionpublic MockAction withJson(io.inversion.json.JSNode json)
public java.lang.String getJsonUrl()
public MockAction withJsonUrl(java.lang.String jsonUrl)
public io.inversion.json.JSNode getJson()
public int getStatusCode()
public MockAction wihtStatusCode(int statusCode)
public java.lang.String getStatus()
public MockAction withStatus(java.lang.String status)
public boolean isCancelRequest()
public MockAction withCancelRequest(boolean cancelRequest)
Copyright © 2023 Rocket Partners, LLC. All rights reserved.