org.jboss.resteasy.util
Class MediaTypeHelper
java.lang.Object
org.jboss.resteasy.util.MediaTypeHelper
public class MediaTypeHelper
- extends Object
- Version:
- $Revision: 1 $
- Author:
- Bill Burke
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
MediaTypeHelper
public MediaTypeHelper()
getConsumes
public static javax.ws.rs.core.MediaType getConsumes(Class declaring,
AccessibleObject method)
getProduces
public static javax.ws.rs.core.MediaType getProduces(Class declaring,
Method method)
getProduces
public static javax.ws.rs.core.MediaType getProduces(Class declaring,
Method method,
javax.ws.rs.core.MediaType defaultProduces)
getQ
public static float getQ(javax.ws.rs.core.MediaType type)
getQWithParamInfo
public static float getQWithParamInfo(javax.ws.rs.core.MediaType type)
isCompositeWildcardSubtype
public static boolean isCompositeWildcardSubtype(String subtype)
- subtypes like application/*+xml
- Parameters:
subtype
-
- Returns:
isWildcardCompositeSubtype
public static boolean isWildcardCompositeSubtype(String subtype)
- subtypes like application/*+xml
- Parameters:
subtype
-
- Returns:
isComposite
public static boolean isComposite(String subtype)
compareWeight
public static int compareWeight(javax.ws.rs.core.MediaType one,
javax.ws.rs.core.MediaType two)
sameWeight
public static boolean sameWeight(javax.ws.rs.core.MediaType one,
javax.ws.rs.core.MediaType two)
sortByWeight
public static void sortByWeight(List<javax.ws.rs.core.MediaType> types)
getBestMatch
public static javax.ws.rs.core.MediaType getBestMatch(List<javax.ws.rs.core.MediaType> desired,
List<javax.ws.rs.core.MediaType> provided)
parseHeader
public static List<javax.ws.rs.core.MediaType> parseHeader(String header)
equivalent
public static boolean equivalent(javax.ws.rs.core.MediaType m1,
javax.ws.rs.core.MediaType m2)
equivalentParams
public static boolean equivalentParams(javax.ws.rs.core.MediaType m1,
javax.ws.rs.core.MediaType m2)
Copyright © 2013 JBoss by Red Hat. All Rights Reserved.