com.aspose.network
Class ContentType

java.lang.Object
  extended by com.aspose.network.ContentType

public class ContentType
extends Object

Typed Content-Type header We parse the type during construction and set. null and string.empty will throw for construction,set and mediatype/subtype constructors set isPersisted to false. isPersisted needs to be tracked seperately than isChanged because isChanged only determines if the cached value should be used. isPersisted tracks if the object has been persisted. However, obviously if isChanged is true the object isn't persisted. If any subcomponents are changed, isChanged is set to true and isPersisted is false ToString caches the value until a isChanged is true, then it recomputes the full value.


Constructor Summary
ContentType()
           
ContentType(String contentType)
           ctor.
 
Method Summary
 boolean equals(Object rparam)
           
 String getBoundary()
           
 String getCharSet()
           
 String getMediaType()
           Gets the media type.
 String getName()
           
 HashMap<String,String> getParameters()
           
 int hashCode()
           
 void setBoundary(String value)
           
 void setCharSet(String value)
           
 void setMediaType(String value)
           
 void setName(String value)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ContentType

public ContentType()

ContentType

public ContentType(String contentType)

ctor.

Parameters:
contentType - Unparsed value of the Content-Type header.
Method Detail

getBoundary

public String getBoundary()

setBoundary

public void setBoundary(String value)

getCharSet

public String getCharSet()

setCharSet

public void setCharSet(String value)

getMediaType

public String getMediaType()

Gets the media type.


setMediaType

public void setMediaType(String value)

getName

public String getName()

setName

public void setName(String value)

getParameters

public HashMap<String,String> getParameters()

toString

public String toString()
Overrides:
toString in class Object

equals

public boolean equals(Object rparam)
Overrides:
equals in class Object

hashCode

public int hashCode()
Overrides:
hashCode in class Object


Copyright (c) 2002-2011 Aspose Pty Ltd. All Rights Reserved.