org.jclouds.io
Class ContentMetadataCodec.DefaultContentMetadataCodec
java.lang.Object
org.jclouds.io.ContentMetadataCodec.DefaultContentMetadataCodec
- All Implemented Interfaces:
- ContentMetadataCodec
- Enclosing interface:
- ContentMetadataCodec
public static class ContentMetadataCodec.DefaultContentMetadataCodec
- extends Object
- implements ContentMetadataCodec
Default implementation, in accordance with HTTP 1.1 spec.
- Author:
- aled
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
logger
protected Logger logger
ContentMetadataCodec.DefaultContentMetadataCodec
@Inject
public ContentMetadataCodec.DefaultContentMetadataCodec(DateCodecFactory dateCodecs)
getExpiresDateCodec
protected DateCodec getExpiresDateCodec()
toHeaders
public com.google.common.collect.Multimap<String,String> toHeaders(ContentMetadata md)
- Description copied from interface:
ContentMetadataCodec
- Generates standard HTTP headers for the give metadata.
- Specified by:
toHeaders in interface ContentMetadataCodec
fromHeaders
public void fromHeaders(MutableContentMetadata contentMetadata,
com.google.common.collect.Multimap<String,String> headers)
- Description copied from interface:
ContentMetadataCodec
- Sets properties related to the http headers listed in
ContentMetadata.HTTP_HEADERS
- Specified by:
fromHeaders in interface ContentMetadataCodec
parseExpires
public Date parseExpires(String expires)
- Description copied from interface:
ContentMetadataCodec
- Parses the 'Expires' header.
If invalid, returns a date in the past (in accordance with HTTP 1.1 client spec).
- Specified by:
parseExpires in interface ContentMetadataCodec
Copyright © 2009-2013 jclouds. All Rights Reserved.