org.openrdf.http.object.util
Class Accepter
java.lang.Object
org.openrdf.http.object.util.Accepter
public class Accepter
- extends Object
Collection of Accept header entries.
- Author:
- James Leigh
Accepter
public Accepter()
Accepter
public Accepter(String accept)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
Accepter
public Accepter(String... mediaTypes)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
Accepter
public Accepter(Collection<MimeType> mediaTypes)
parse
public static MimeType parse(String mediaType)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
isCompatible
public static boolean isCompatible(MimeType accept,
MimeType media)
addMimeType
public void addMimeType(String mediaType)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
addMimeType
public void addMimeType(MimeType mediaType)
toString
public String toString()
- Overrides:
toString in class Object
isAcceptable
public boolean isAcceptable(String mediaType)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
isAcceptable
public boolean isAcceptable(String[] mediaTypes)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
getAcceptable
public SortedSet<? extends MimeType> getAcceptable()
throws MimeTypeParseException
- Throws:
MimeTypeParseException
getCompatible
public SortedSet<? extends MimeType> getCompatible(String mediaType)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
getCompatible
public SortedSet<? extends MimeType> getCompatible(String[] mediaTypes)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
getCompatible
public SortedSet<? extends MimeType> getCompatible(Collection<? extends MimeType> mediaTypes)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
getAcceptable
public List<? extends MimeType> getAcceptable(String mediaType)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
getAcceptable
public List<? extends MimeType> getAcceptable(String[] mediaTypes)
throws MimeTypeParseException
- Throws:
MimeTypeParseException
Copyright © 2004-2010 James Leigh Services Inc.. All Rights Reserved.