ContentType

Inheritance: java.lang.Object

public class ContentType

Represents a Content-Type header.

Constructors

ConstructorDescription
ContentType()Initializes a new instance of the ContentType class.
ContentType(String contentType)Initializes a new instance of the ContentType class.

Methods

MethodDescription
equals(Object obj)Determines whether the specified Object is equal to this instance.
getBoundary()Gets or sets the value of the boundary parameter included in the Content-Type header.
getCharSet()Gets or sets the value of the charset parameter.
getClass()
getMediaType()Gets or sets the internet media type.
getName()Gets or sets the value of the name parameter.
getParameters()Gets the dictionary that contains the parameters.
hashCode()Returns a hash code for this instance.
notify()
notifyAll()
setBoundary(String value)Gets or sets the value of the boundary parameter included in the Content-Type header.
setCharSet(String value)Gets or sets the value of the charset parameter.
setMediaType(String value)Gets or sets the internet media type.
setName(String value)Gets or sets the value of the name parameter.
toString()Returns a String that represents this instance.
wait()
wait(long arg0)
wait(long arg0, int arg1)

ContentType()

public ContentType()

Initializes a new instance of the ContentType class.

ContentType(String contentType)

public ContentType(String contentType)

Initializes a new instance of the ContentType class.

Parameters:

ParameterTypeDescription
contentTypejava.lang.StringType of the content.

equals(Object obj)

public boolean equals(Object obj)

Determines whether the specified Object is equal to this instance.

Parameters:

ParameterTypeDescription
objjava.lang.ObjectThe Object to compare with this instance.

Returns: boolean - true if the specified Object is equal to this instance; otherwise, false .

getBoundary()

public final String getBoundary()

Gets or sets the value of the boundary parameter included in the Content-Type header.

Value: A string that contains the value of boundary parameter.

Returns: java.lang.String

getCharSet()

public final String getCharSet()

Gets or sets the value of the charset parameter.

Value: A string that contains the value of charset parameter.

Returns: java.lang.String

getClass()

public final native Class<?> getClass()

Returns: java.lang.Class

getMediaType()

public final String getMediaType()

Gets or sets the internet media type.

Value: A String that contains the media type.

Returns: java.lang.String

getName()

public final String getName()

Gets or sets the value of the name parameter.

Value: A String that contains the name.

Returns: java.lang.String

getParameters()

public final TrackingStringDictionary getParameters()

Gets the dictionary that contains the parameters.

Value: A StringDictionary that contains name and value pairs.

Returns: TrackingStringDictionary

hashCode()

public int hashCode()

Returns a hash code for this instance.

Returns: int - A hash code for this instance, suitable for use in hashing algorithms and data structures like a hash table.

notify()

public final native void notify()

notifyAll()

public final native void notifyAll()

setBoundary(String value)

public final void setBoundary(String value)

Gets or sets the value of the boundary parameter included in the Content-Type header.

Value: A string that contains the value of boundary parameter.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setCharSet(String value)

public final void setCharSet(String value)

Gets or sets the value of the charset parameter.

Value: A string that contains the value of charset parameter.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setMediaType(String value)

public final void setMediaType(String value)

Gets or sets the internet media type.

Value: A String that contains the media type.

Parameters:

ParameterTypeDescription
valuejava.lang.String

setName(String value)

public final void setName(String value)

Gets or sets the value of the name parameter.

Value: A String that contains the name.

Parameters:

ParameterTypeDescription
valuejava.lang.String

toString()

public String toString()

Returns a String that represents this instance.

Returns: java.lang.String - A String that represents this instance.

wait()

public final void wait()

wait(long arg0)

public final native void wait(long arg0)

Parameters:

ParameterTypeDescription
arg0long

wait(long arg0, int arg1)

public final void wait(long arg0, int arg1)

Parameters:

ParameterTypeDescription
arg0long
arg1int