org.apache.commons.httpclient.methods.multipart

Class PartBase

public abstract class PartBase extends Part

Provides setters and getters for the basic Part properties.

Author: Michael Becke

Constructor Summary
PartBase(String name, String contentType, String charSet, String transferEncoding)
Constructor.
Method Summary
StringgetCharSet()
Return the character encoding of this part.
StringgetContentType()
Returns the content type of this part.
StringgetName()
Returns the name.
StringgetTransferEncoding()
Returns the transfer encoding of this part.
voidsetCharSet(String charSet)
Sets the character encoding.
voidsetContentType(String contentType)
Sets the content type.
voidsetName(String name)
Sets the part name.
voidsetTransferEncoding(String transferEncoding)
Sets the transfer encoding.

Constructor Detail

PartBase

public PartBase(String name, String contentType, String charSet, String transferEncoding)
Constructor.

Parameters: name The name of the part contentType The content type, or null charSet The character encoding, or null transferEncoding The transfer encoding, or null

Method Detail

getCharSet

public String getCharSet()
Return the character encoding of this part.

Returns: String The name.

getContentType

public String getContentType()
Returns the content type of this part.

Returns: String The name.

getName

public String getName()
Returns the name.

Returns: The name.

See Also: getName

getTransferEncoding

public String getTransferEncoding()
Returns the transfer encoding of this part.

Returns: String The name.

setCharSet

public void setCharSet(String charSet)
Sets the character encoding.

Parameters: charSet the character encoding, or null to exclude the character encoding header

setContentType

public void setContentType(String contentType)
Sets the content type.

Parameters: contentType the content type, or null to exclude the content type header

setName

public void setName(String name)
Sets the part name.

Parameters: name

setTransferEncoding

public void setTransferEncoding(String transferEncoding)
Sets the transfer encoding.

Parameters: transferEncoding the transfer encoding, or null to exclude the transfer encoding header

Copyright (c) 1999-2005 - Apache Software Foundation