public class ContentType extends Object
Constructor and Description |
---|
ContentType() |
ContentType(String boundary,
String charSet,
String mediaType,
String name,
List<ContentTypeParameter> parameters)
Initializes a new instance of the ContentType
|
Modifier and Type | Method and Description |
---|---|
ContentType |
addParametersItem(ContentTypeParameter parametersItem)
Add an item to parameters and return this.
|
ContentType |
boundary(String boundary)
Set boundary and return this.
|
ContentType |
charSet(String charSet)
Set charSet and return this.
|
boolean |
equals(Object o) |
String |
getBoundary()
The boundary parameter included in the Content-Type header.
|
String |
getCharSet()
CharSet parameter.
|
String |
getMediaType()
The internet media type.
|
String |
getName()
Name parameter.
|
List<ContentTypeParameter> |
getParameters()
Full list of parameters
|
int |
hashCode() |
ContentType |
mediaType(String mediaType)
Set mediaType and return this.
|
ContentType |
name(String name)
Set name and return this.
|
ContentType |
parameters(List<ContentTypeParameter> parameters)
Set parameters and return this.
|
void |
setBoundary(String boundary)
Set boundary.
|
void |
setCharSet(String charSet)
Set charSet.
|
void |
setMediaType(String mediaType)
Set mediaType.
|
void |
setName(String name)
Set name.
|
void |
setParameters(List<ContentTypeParameter> parameters)
Set parameters.
|
String |
toString() |
public ContentType()
public ContentType(String boundary, String charSet, String mediaType, String name, List<ContentTypeParameter> parameters)
boundary
- The boundary parameter included in the Content-Type header.charSet
- CharSet parameter.mediaType
- The internet media type.name
- Name parameter.parameters
- Full list of parameterspublic ContentType boundary(String boundary)
boundary
- The boundary parameter included in the Content-Type header.public String getBoundary()
public void setBoundary(String boundary)
boundary
- The boundary parameter included in the Content-Type header.public ContentType charSet(String charSet)
charSet
- CharSet parameter.public String getCharSet()
public void setCharSet(String charSet)
charSet
- CharSet parameter.public ContentType mediaType(String mediaType)
mediaType
- The internet media type.public String getMediaType()
public void setMediaType(String mediaType)
mediaType
- The internet media type.public ContentType name(String name)
name
- Name parameter.public String getName()
public void setName(String name)
name
- Name parameter.public ContentType parameters(List<ContentTypeParameter> parameters)
parameters
- Full list of parameterspublic ContentType addParametersItem(ContentTypeParameter parametersItem)
parametersItem
- An item of: Full list of parameterspublic List<ContentTypeParameter> getParameters()
public void setParameters(List<ContentTypeParameter> parameters)
parameters
- Full list of parametersCopyright © 2020. All rights reserved.