org.apache.myfaces.commons.resourcehandler
Class ResourceUtils
java.lang.Object
org.apache.myfaces.commons.resourcehandler.ResourceUtils
public class ResourceUtils
- extends Object
Utility methods needed in PackagedResource and PackagedResourceHandler.
- Author:
- Jakob Korherr
Method Summary |
static boolean |
isGZIPEncodingAccepted(String acceptEncodingHeader)
Checks if the user agent supports GZIP compression on basis of the "Accept-Encoding" header field. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ResourceUtils
public ResourceUtils()
isGZIPEncodingAccepted
public static boolean isGZIPEncodingAccepted(String acceptEncodingHeader)
- Checks if the user agent supports GZIP compression on basis of the "Accept-Encoding" header field.
Created according to RFC2616, section 14.3 Accept-Encoding.
Some examples of Accept-Encoding:
Accept-Encoding: gzip, deflate
Accept-Encoding:
Accept-Encoding: *
Accept-Encoding: compress;q=0.5, gzip;q=1.0
Accept-Encoding: gzip;q=1.0, identity; q=0.5, *;q=0
- Parameters:
acceptEncodingHeader
-
- Returns:
Copyright © 2007-2011 The Apache Software Foundation. All Rights Reserved.