use of com.aliyun.oss.common.comm.RequestMessage in project aliyun-oss-java-sdk by aliyun.
the class OSSBucketOperation method getBucketReplicationProgress.
/**
* Get bucket replication progress.
*/
public BucketReplicationProgress getBucketReplicationProgress(GetBucketReplicationProgressRequest getBucketReplicationProgressRequest) throws OSSException, ClientException {
assertParameterNotNull(getBucketReplicationProgressRequest, "getBucketReplicationProgressRequest");
assertParameterNotNull(getBucketReplicationProgressRequest.getReplicationRuleID(), "replicationRuleID");
String bucketName = getBucketReplicationProgressRequest.getBucketName();
assertParameterNotNull(bucketName, "bucketName");
ensureBucketNameValid(bucketName);
Map<String, String> params = new HashMap<String, String>();
params.put(RequestParameters.SUBRESOURCE_REPLICATION_PROGRESS, null);
params.put(RequestParameters.RULE_ID, getBucketReplicationProgressRequest.getReplicationRuleID());
RequestMessage request = new OSSRequestMessageBuilder(getInnerClient()).setEndpoint(getEndpoint()).setMethod(HttpMethod.GET).setBucket(bucketName).setParameters(params).setOriginalRequest(getBucketReplicationProgressRequest).build();
return doOperation(request, getBucketReplicationProgressResponseParser, bucketName, null, true);
}
use of com.aliyun.oss.common.comm.RequestMessage in project aliyun-oss-java-sdk by aliyun.
the class OSSBucketOperation method deleteImageStyle.
public void deleteImageStyle(String bucketName, String styleName, GenericRequest genericRequest) throws OSSException, ClientException {
assertParameterNotNull(bucketName, "bucketName");
assertParameterNotNull(styleName, "styleName");
ensureBucketNameValid(bucketName);
Map<String, String> params = new HashMap<String, String>();
params.put(SUBRESOURCE_STYLE, null);
params.put(STYLE_NAME, styleName);
RequestMessage request = new OSSRequestMessageBuilder(getInnerClient()).setEndpoint(getEndpoint()).setMethod(HttpMethod.DELETE).setBucket(bucketName).setParameters(params).setOriginalRequest(genericRequest).build();
doOperation(request, emptyResponseParser, bucketName, null);
}
use of com.aliyun.oss.common.comm.RequestMessage in project aliyun-oss-java-sdk by aliyun.
the class OSSBucketOperation method deleteBucketLogging.
/**
* Delete bucket logging.
*/
public void deleteBucketLogging(GenericRequest genericRequest) throws OSSException, ClientException {
assertParameterNotNull(genericRequest, "genericRequest");
String bucketName = genericRequest.getBucketName();
assertParameterNotNull(bucketName, "bucketName");
ensureBucketNameValid(bucketName);
Map<String, String> params = new HashMap<String, String>();
params.put(SUBRESOURCE_LOGGING, null);
RequestMessage request = new OSSRequestMessageBuilder(getInnerClient()).setEndpoint(getEndpoint()).setMethod(HttpMethod.DELETE).setBucket(bucketName).setParameters(params).setOriginalRequest(genericRequest).build();
doOperation(request, emptyResponseParser, bucketName, null);
}
use of com.aliyun.oss.common.comm.RequestMessage in project aliyun-oss-java-sdk by aliyun.
the class OSSBucketOperation method putImageStyle.
/**
* put image style
*/
public void putImageStyle(PutImageStyleRequest putImageStyleRequest) throws OSSException, ClientException {
assertParameterNotNull(putImageStyleRequest, "putImageStyleRequest");
String bucketName = putImageStyleRequest.GetBucketName();
String styleName = putImageStyleRequest.GetStyleName();
assertParameterNotNull(styleName, "styleName");
assertParameterNotNull(bucketName, "bucketName");
ensureBucketNameValid(bucketName);
Map<String, String> params = new HashMap<String, String>();
params.put(SUBRESOURCE_STYLE, null);
params.put(STYLE_NAME, styleName);
RequestMessage request = new OSSRequestMessageBuilder(getInnerClient()).setEndpoint(getEndpoint()).setMethod(HttpMethod.PUT).setBucket(bucketName).setParameters(params).setOriginalRequest(putImageStyleRequest).setInputStreamWithLength(putImageStyleRequestMarshaller.marshall(putImageStyleRequest)).build();
doOperation(request, emptyResponseParser, bucketName, null);
}
use of com.aliyun.oss.common.comm.RequestMessage in project aliyun-oss-java-sdk by aliyun.
the class OSSBucketOperation method deleteBucketImage.
/**
* Delete bucket image attributes.
*/
public void deleteBucketImage(String bucketName, GenericRequest genericRequest) throws OSSException, ClientException {
assertParameterNotNull(bucketName, "bucketName");
ensureBucketNameValid(bucketName);
Map<String, String> params = new HashMap<String, String>();
params.put(SUBRESOURCE_IMG, null);
RequestMessage request = new OSSRequestMessageBuilder(getInnerClient()).setEndpoint(getEndpoint()).setMethod(HttpMethod.DELETE).setBucket(bucketName).setParameters(params).setOriginalRequest(genericRequest).build();
doOperation(request, emptyResponseParser, bucketName, null);
}
Aggregations