public class Bucket extends GenericResult
Bucket name is globally unique in OSS and is immutable. Every object must belong to a bucket. An application such as picture sharing website could be mapped to one or multiple buckets. An OSS account could only create up to 10 bucket. And there's no limit on the files count or size under a bucket.
Bucket naming rules:Constructor and Description |
---|
Bucket()
Default constructor.
|
Bucket(String name)
Constructor with the bucket name parameter.
|
Bucket(String name,
String requestId) |
Modifier and Type | Method and Description |
---|---|
String |
getAccessMonitor() |
Date |
getCreationDate()
Gets the bucket's creation time.
|
String |
getExtranetEndpoint()
Gets the external endpoint.
|
String |
getHnsStatus() |
String |
getIntranetEndpoint()
Gets the internal endpoint.
|
String |
getLocation()
Gets the bucket location.
|
String |
getName()
Gets the bucket name
|
Owner |
getOwner()
Gets the
Owner . |
String |
getRegion()
Gets the region.
|
String |
getResourceGroupId()
Gets the id of resource group.
|
StorageClass |
getStorageClass()
Gets the storage class
|
String |
getXcType() |
void |
setAccessMonitor(String accessMonitor) |
void |
setCreationDate(Date creationDate)
Sets teh bucket's creation time.(it's only used by SDK itself).
|
void |
setExtranetEndpoint(String endpoint)
Sets the external endpoint.
|
void |
setHnsStatus(String hnsStatus)
set hierarchical namespace status.
|
void |
setIntranetEndpoint(String endpoint)
Sets the internal endpoint.
|
void |
setLocation(String location)
Sets the bucket location.
|
void |
setName(String name)
Sets the bucket name (should only be used by the SDK itself).
|
void |
setOwner(Owner owner)
Sets the bucket owner (only used by SDK itself).
|
void |
setRegion(String region)
Sets the region.
|
void |
setResourceGroupId(String resourceGroupId)
set the id of resource group.
|
void |
setStorageClass(StorageClass storageClass)
Sets the bucket's storage class
|
void |
setXcType(String xcType) |
String |
toString()
The override of toString().
|
getClientCRC, getRequestId, getResponse, getServerCRC, setClientCRC, setRequestId, setResponse, setServerCRC
public Bucket()
public Bucket(String name)
name
- Bucket name.public String toString()
public Owner getOwner()
Owner
.public void setOwner(Owner owner)
owner
- Bucket owner.public Date getCreationDate()
public void setCreationDate(Date creationDate)
creationDate
- Bucket's creation time.public String getName()
public void setName(String name)
name
- Bucket name.public String getLocation()
public void setLocation(String location)
location
- the bucket locationpublic StorageClass getStorageClass()
public void setStorageClass(StorageClass storageClass)
storageClass
- the storage classpublic String getExtranetEndpoint()
public void setExtranetEndpoint(String endpoint)
endpoint
- external endpointpublic String getIntranetEndpoint()
public void setIntranetEndpoint(String endpoint)
endpoint
- Internal endpointpublic String getRegion()
public void setRegion(String region)
region
- Regionpublic String getHnsStatus()
HnsStatus
toString()
public void setHnsStatus(String hnsStatus)
hnsStatus
- the hierarchical namespace status.public String getResourceGroupId()
public void setResourceGroupId(String resourceGroupId)
resourceGroupId
- the resource group id.public String getXcType()
public void setXcType(String xcType)
public String getAccessMonitor()
public void setAccessMonitor(String accessMonitor)
Copyright © 2024. All Rights Reserved.