Class B2Bucket
- java.lang.Object
-
- com.backblaze.b2.client.structures.B2Bucket
-
public class B2Bucket extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description B2Bucket(java.lang.String accountId, java.lang.String bucketId, java.lang.String bucketName, java.lang.String bucketType, java.util.Map<java.lang.String,java.lang.String> bucketInfo, java.util.List<B2CorsRule> corsRules, java.util.List<B2LifecycleRule> lifecycleRules, java.util.Set<java.lang.String> options, B2AuthorizationFilteredResponseField<B2BucketFileLockConfiguration> fileLockConfiguration, B2AuthorizationFilteredResponseField<B2BucketServerSideEncryption> defaultServerSideEncryption, B2AuthorizationFilteredResponseField<B2BucketReplicationConfiguration> replicationConfiguration, int revision)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object o)
java.lang.String
getAccountId()
java.lang.String
getBucketId()
java.util.Map<java.lang.String,java.lang.String>
getBucketInfo()
java.lang.String
getBucketName()
java.lang.String
getBucketType()
java.util.List<B2CorsRule>
getCorsRules()
B2BucketServerSideEncryption
getDefaultServerSideEncryption()
Returns settings for default bucket encryption (i.e., mode and algorithm) or null if there are none.B2BucketFileLockConfiguration
getFileLockConfiguration()
Returns bucket file lock configuration.java.util.List<B2LifecycleRule>
getLifecycleRules()
java.util.Set<java.lang.String>
getOptions()
B2BucketReplicationConfiguration
getReplicationConfiguration()
Returns settings for bucket replication configuration or null if there are none.int
getRevision()
int
hashCode()
boolean
isClientAuthorizedToReadDefaultServerSideEncryption()
Indicates whether client is authorized to read default bucket encryption settings for bucketboolean
isClientAuthorizedToReadFileLockConfiguration()
Indicates whether client is authorized to read file lock configuration settings for bucketboolean
isClientAuthorizedToReadReplicationConfiguration()
Indicates whether client is authorized to read replication configuration settings for bucketjava.lang.String
toString()
-
-
-
Constructor Detail
-
B2Bucket
public B2Bucket(java.lang.String accountId, java.lang.String bucketId, java.lang.String bucketName, java.lang.String bucketType, java.util.Map<java.lang.String,java.lang.String> bucketInfo, java.util.List<B2CorsRule> corsRules, java.util.List<B2LifecycleRule> lifecycleRules, java.util.Set<java.lang.String> options, B2AuthorizationFilteredResponseField<B2BucketFileLockConfiguration> fileLockConfiguration, B2AuthorizationFilteredResponseField<B2BucketServerSideEncryption> defaultServerSideEncryption, B2AuthorizationFilteredResponseField<B2BucketReplicationConfiguration> replicationConfiguration, int revision)
-
-
Method Detail
-
getAccountId
public java.lang.String getAccountId()
-
getBucketId
public java.lang.String getBucketId()
-
getBucketName
public java.lang.String getBucketName()
-
getBucketType
public java.lang.String getBucketType()
-
getBucketInfo
public java.util.Map<java.lang.String,java.lang.String> getBucketInfo()
-
getCorsRules
public java.util.List<B2CorsRule> getCorsRules()
-
getLifecycleRules
public java.util.List<B2LifecycleRule> getLifecycleRules()
-
getOptions
public java.util.Set<java.lang.String> getOptions()
-
getRevision
public int getRevision()
-
isClientAuthorizedToReadFileLockConfiguration
public boolean isClientAuthorizedToReadFileLockConfiguration()
Indicates whether client is authorized to read file lock configuration settings for bucket- Returns:
- true iff client is authorized to read value of fileLockConfiguration field in B2Bucket
-
getFileLockConfiguration
public B2BucketFileLockConfiguration getFileLockConfiguration() throws B2ForbiddenException
Returns bucket file lock configuration. Throws B2ForbiddenException if client is not authorized to read bucket file lock configuration.- Returns:
- file lock configuration
- Throws:
B2ForbiddenException
- if client is not authorized to read fileLockConfiguration
-
isClientAuthorizedToReadDefaultServerSideEncryption
public boolean isClientAuthorizedToReadDefaultServerSideEncryption()
Indicates whether client is authorized to read default bucket encryption settings for bucket- Returns:
- true iff client is authorized to read value of defaultServerSideEncryption field in B2Bucket
-
getDefaultServerSideEncryption
public B2BucketServerSideEncryption getDefaultServerSideEncryption() throws B2ForbiddenException
Returns settings for default bucket encryption (i.e., mode and algorithm) or null if there are none. Throws B2ForbiddenException if client is not authorized to read bucket default encryption settings.- Returns:
- default bucket encryption settings
- Throws:
B2ForbiddenException
- if client is not authorized to read defaultServerSideEncryption field
-
isClientAuthorizedToReadReplicationConfiguration
public boolean isClientAuthorizedToReadReplicationConfiguration()
Indicates whether client is authorized to read replication configuration settings for bucket- Returns:
- true iff client is authorized to read value of replicationConfiguration field in B2Bucket
-
getReplicationConfiguration
public B2BucketReplicationConfiguration getReplicationConfiguration() throws B2ForbiddenException
Returns settings for bucket replication configuration or null if there are none. Throws B2ForbiddenException if client is not authorized to read bucket replication configuration settings.- Returns:
- replication configuration settings
- Throws:
B2ForbiddenException
- if client is not authorized to read replicationConfiguration field
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object o)
- Overrides:
equals
in classjava.lang.Object
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
-