Package org.mockserver.model
Class HttpTemplate
- java.lang.Object
-
- org.mockserver.model.ObjectWithReflectiveEqualsHashCodeToString
-
- org.mockserver.model.ObjectWithJsonToString
-
- org.mockserver.model.Action<HttpTemplate>
-
- org.mockserver.model.HttpTemplate
-
public class HttpTemplate extends Action<HttpTemplate>
- Author:
- jamesdbloom
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
HttpTemplate.TemplateType
-
Nested classes/interfaces inherited from class org.mockserver.model.Action
Action.Direction, Action.Type
-
-
Constructor Summary
Constructors Constructor Description HttpTemplate(HttpTemplate.TemplateType type)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getTemplate()
HttpTemplate.TemplateType
getTemplateType()
Action.Type
getType()
void
setActionType(Action.Type actionType)
HttpTemplate
shallowClone()
static HttpTemplate
template(HttpTemplate.TemplateType type)
Static builder to create an template for responding or forwarding requests.static HttpTemplate
template(HttpTemplate.TemplateType type, String template)
Static builder to create an template for responding or forwarding requests.HttpTemplate
withTemplate(String template)
-
Methods inherited from class org.mockserver.model.ObjectWithJsonToString
toString
-
Methods inherited from class org.mockserver.model.ObjectWithReflectiveEqualsHashCodeToString
equals, fieldsExcludedFromEqualsAndHashCode, hashCode, key
-
-
-
-
Constructor Detail
-
HttpTemplate
public HttpTemplate(HttpTemplate.TemplateType type)
-
-
Method Detail
-
template
public static HttpTemplate template(HttpTemplate.TemplateType type)
Static builder to create an template for responding or forwarding requests.
-
template
public static HttpTemplate template(HttpTemplate.TemplateType type, String template)
Static builder to create an template for responding or forwarding requests.- Parameters:
template
- the template for the response or request
-
getTemplateType
public HttpTemplate.TemplateType getTemplateType()
-
withTemplate
public HttpTemplate withTemplate(String template)
-
getTemplate
public String getTemplate()
-
setActionType
public void setActionType(Action.Type actionType)
-
getType
public Action.Type getType()
- Specified by:
getType
in classAction<HttpTemplate>
-
shallowClone
public HttpTemplate shallowClone()
-
-