> + }
> + if (attributes.contains(XATTR_EXPIRES)) {
> + ByteBuffer buf = ByteBuffer.allocate(view.size(XATTR_EXPIRES));
> + view.read(XATTR_EXPIRES, buf);
> + buf.flip();
> + expires = new Date(buf.asLongBuffer().get());
> + }
> + ImmutableMap.Builder<String, String> userMetadata =
> ImmutableMap.builder();
> + for (String attribute : attributes) {
> + if (!attribute.startsWith(XATTR_USER_METADATA_PREFIX)) {
> + continue;
> + }
> + ByteBuffer buf = ByteBuffer.allocate(view.size(attribute));
> + view.read(attribute, buf);
> + String value = new String(buf.array(), Charsets.UTF_8);
> +
> userMetadata.put(attribute.substring(XATTR_USER_METADATA_PREFIX.length()),
> value);
Hope the JVM can figure this out?
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/443/files#r16027474