/** *{@inheritDoc} */ @Override public int compareTo(ObjectMetadata o) { return (this == o) ? 0 : getUri().compareTo(o.getUri()); }
/** *{@inheritDoc} */ @Override public int compareTo(ObjectMetadata o) { return (this == o) ? 0 : getUri().compareTo(o.getUri()); }
/** *{@inheritDoc} */ @Override public int compareTo(ObjectMetadata o) { return (this == o) ? 0 : getUri().compareTo(o.getUri()); }
/** *{@inheritDoc} */ @Override public int compareTo(ObjectMetadata o) { return (this == o) ? 0 : getUri().compareTo(o.getUri()); }
/** *{@inheritDoc} */ @Override public int compareTo(ObjectMetadata o) { return (this == o) ? 0 : getUri().compareTo(o.getUri()); }
public MutableObjectMetadataImpl(ObjectMetadata from) { this.storageClass = StorageClass.STANDARD; this.contentMetadata = new BaseMutableContentMetadata(); HttpUtils.copy(from.getContentMetadata(), this.contentMetadata); this.key = from.getKey(); this.uri = from.getUri(); this.bucket = from.getBucket(); }
public MutableObjectMetadataImpl(ObjectMetadata from) { this.storageClass = StorageClass.STANDARD; this.contentMetadata = new BaseMutableContentMetadata(); HttpUtils.copy(from.getContentMetadata(), this.contentMetadata); this.key = from.getKey(); this.uri = from.getUri(); this.bucket = from.getBucket(); }
public MutableObjectMetadataImpl(ObjectMetadata from) { this.storageClass = StorageClass.STANDARD; this.contentMetadata = new BaseMutableContentMetadata(); HttpUtils.copy(from.getContentMetadata(), this.contentMetadata); this.key = from.getKey(); this.uri = from.getUri(); this.bucket = from.getBucket(); }
public MutableObjectMetadataImpl(ObjectMetadata from) { this.storageClass = StorageClass.STANDARD; this.contentMetadata = new BaseMutableContentMetadata(); HttpUtils.copy(from.getContentMetadata(), this.contentMetadata); this.key = from.getKey(); this.uri = from.getUri(); this.bucket = from.getBucket(); }
public MutableObjectMetadataImpl(ObjectMetadata from) { this.storageClass = StorageClass.STANDARD; this.contentMetadata = new BaseMutableContentMetadata(); HttpUtils.copy(from.getContentMetadata(), this.contentMetadata); this.key = from.getKey(); this.uri = from.getUri(); this.bucket = from.getBucket(); }
public MutableBlobMetadata apply(ObjectMetadata from) { if (from == null) return null; MutableBlobMetadata to = new MutableBlobMetadataImpl(); HttpUtils.copy(from.getContentMetadata(), to.getContentMetadata()); try { AccessControlList bucketAcl = bucketAcls.getUnchecked(from.getBucket()); if (bucketAcl.hasPermission(GroupGranteeURI.ALL_USERS, Permission.READ)) to.setPublicUri(from.getUri()); } catch (CacheLoader.InvalidCacheLoadException e) { // nulls not permitted from cache loader } to.setUri(from.getUri()); to.setContainer(from.getBucket()); to.setETag(from.getETag()); to.setName(from.getKey()); to.setLastModified(from.getLastModified()); to.setUserMetadata(from.getUserMetadata()); to.setLocation(locationOfBucket.apply(from.getBucket())); String directoryName = ifDirectoryReturnName.execute(to); if (directoryName != null) { to.setName(directoryName); to.setType(StorageType.RELATIVE_PATH); } else { to.setType(StorageType.BLOB); } return to; } }
public MutableBlobMetadata apply(ObjectMetadata from) { if (from == null) return null; MutableBlobMetadata to = new MutableBlobMetadataImpl(); HttpUtils.copy(from.getContentMetadata(), to.getContentMetadata()); try { AccessControlList bucketAcl = bucketAcls.getUnchecked(from.getBucket()); if (bucketAcl.hasPermission(GroupGranteeURI.ALL_USERS, Permission.READ)) to.setPublicUri(from.getUri()); } catch (CacheLoader.InvalidCacheLoadException e) { // nulls not permitted from cache loader } to.setUri(from.getUri()); to.setContainer(from.getBucket()); to.setETag(from.getETag()); to.setName(from.getKey()); to.setLastModified(from.getLastModified()); to.setUserMetadata(from.getUserMetadata()); to.setLocation(locationOfBucket.apply(from.getBucket())); String directoryName = ifDirectoryReturnName.execute(to); if (directoryName != null) { to.setName(directoryName); to.setType(StorageType.RELATIVE_PATH); } else { to.setType(StorageType.BLOB); } return to; } }
public MutableBlobMetadata apply(ObjectMetadata from) { if (from == null) return null; MutableBlobMetadata to = new MutableBlobMetadataImpl(); HttpUtils.copy(from.getContentMetadata(), to.getContentMetadata()); to.setUri(from.getUri()); to.setContainer(from.getBucket()); to.setETag(from.getETag()); to.setName(from.getKey()); to.setLastModified(from.getLastModified()); to.setUserMetadata(from.getUserMetadata()); to.setLocation(locationOfBucket.apply(from.getBucket())); to.setType(StorageType.BLOB); to.setSize(from.getContentMetadata().getContentLength()); return to; } }
public MutableBlobMetadata apply(ObjectMetadata from) { if (from == null) return null; MutableBlobMetadata to = new MutableBlobMetadataImpl(); HttpUtils.copy(from.getContentMetadata(), to.getContentMetadata()); to.setUri(from.getUri()); to.setContainer(from.getBucket()); to.setETag(from.getETag()); to.setName(from.getKey()); to.setLastModified(from.getLastModified()); to.setUserMetadata(from.getUserMetadata()); to.setLocation(locationOfBucket.apply(from.getBucket())); to.setType(StorageType.BLOB); to.setSize(from.getContentMetadata().getContentLength()); to.setTier((from.getStorageClass() == null ? ObjectMetadata.StorageClass.STANDARD : from.getStorageClass()).toTier()); return to; } }
public MutableBlobMetadata apply(ObjectMetadata from) { if (from == null) return null; MutableBlobMetadata to = new MutableBlobMetadataImpl(); HttpUtils.copy(from.getContentMetadata(), to.getContentMetadata()); to.setUri(from.getUri()); to.setContainer(from.getBucket()); to.setETag(from.getETag()); to.setName(from.getKey()); to.setLastModified(from.getLastModified()); to.setUserMetadata(from.getUserMetadata()); to.setLocation(locationOfBucket.apply(from.getBucket())); to.setType(StorageType.BLOB); to.setSize(from.getContentMetadata().getContentLength()); to.setTier((from.getStorageClass() == null ? ObjectMetadata.StorageClass.STANDARD : from.getStorageClass()).toTier()); return to; } }