Package org.mockserver.model
Class StringBody
-
public class StringBody extends BodyWithContentType<String>
- Author:
- jamesdbloom
-
-
Field Summary
-
Fields inherited from class org.mockserver.model.BodyWithContentType
contentType
-
-
Constructor Summary
Constructors Constructor Description StringBody(String value)
StringBody(String value, boolean subString)
StringBody(String value, boolean subString, Charset charset)
StringBody(String value, boolean subString, MediaType contentType)
StringBody(String value, byte[] rawBinaryData, boolean subString, MediaType contentType)
StringBody(String value, Charset charset)
StringBody(String value, MediaType contentType)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static StringBody
exact(String body)
static StringBody
exact(String body, Charset charset)
static StringBody
exact(String body, MediaType contentType)
byte[]
getRawBytes()
String
getValue()
boolean
isSubString()
static StringBody
subString(String body)
static StringBody
subString(String body, Charset charset)
static StringBody
subString(String body, MediaType contentType)
String
toString()
-
Methods inherited from class org.mockserver.model.BodyWithContentType
getCharset, getContentType
-
Methods inherited from class org.mockserver.model.ObjectWithReflectiveEqualsHashCodeToString
equals, fieldsExcludedFromEqualsAndHashCode, hashCode, key
-
-
-
-
Method Detail
-
exact
public static StringBody exact(String body)
-
exact
public static StringBody exact(String body, Charset charset)
-
exact
public static StringBody exact(String body, MediaType contentType)
-
subString
public static StringBody subString(String body)
-
subString
public static StringBody subString(String body, Charset charset)
-
subString
public static StringBody subString(String body, MediaType contentType)
-
getRawBytes
public byte[] getRawBytes()
- Overrides:
getRawBytes
in classBody
-
isSubString
public boolean isSubString()
-
toString
public String toString()
- Overrides:
toString
in classObjectWithJsonToString
-
-