org.codehaus.httpcache4j
Class MIMEType

java.lang.Object
  extended by org.codehaus.httpcache4j.MIMEType
All Implemented Interfaces:
java.io.Serializable

public final class MIMEType
extends java.lang.Object
implements java.io.Serializable

Media type used in representations and preferences.

See Also:
MIME types on Wikipedia, Serialized Form

Field Summary
static MIMEType ALL
           
static MIMEType APPLICATION_OCTET_STREAM
           
 
Constructor Summary
MIMEType(java.lang.String MIMEType)
           
MIMEType(java.lang.String primaryType, java.lang.String subType)
           
 
Method Summary
 void addParameter(java.lang.String name, java.lang.String value)
           
 boolean equals(java.lang.Object object)
           
 boolean equals(java.lang.Object o, boolean includeParameters)
           
 java.util.List<Parameter> getParameters()
           
 java.lang.String getPrimaryType()
           
 java.lang.String getSubType()
           
 int hashCode()
           
 boolean includes(MIMEType mimeType)
           
 java.lang.String toString()
           
static MIMEType valueOf(java.lang.String MIMEType)
           
static MIMEType valueOf(java.lang.String primaryType, java.lang.String subType)
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

ALL

public static final MIMEType ALL

APPLICATION_OCTET_STREAM

public static final MIMEType APPLICATION_OCTET_STREAM
Constructor Detail

MIMEType

public MIMEType(java.lang.String MIMEType)

MIMEType

public MIMEType(java.lang.String primaryType,
                java.lang.String subType)
Method Detail

addParameter

public void addParameter(java.lang.String name,
                         java.lang.String value)

getSubType

public java.lang.String getSubType()

getPrimaryType

public java.lang.String getPrimaryType()

equals

public boolean equals(java.lang.Object object)
Overrides:
equals in class java.lang.Object

equals

public boolean equals(java.lang.Object o,
                      boolean includeParameters)

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

includes

public boolean includes(MIMEType mimeType)

getParameters

public java.util.List<Parameter> getParameters()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

valueOf

public static MIMEType valueOf(java.lang.String MIMEType)

valueOf

public static MIMEType valueOf(java.lang.String primaryType,
                               java.lang.String subType)


Copyright © 2008-2009. All Rights Reserved.