Package com.aliyun.openservices.oss.model

Examples of com.aliyun.openservices.oss.model.PutObjectResult


  }

  private OssFile ossUpload(String key, InputStream inputStream, ObjectMetadata metadata) {
    OssFile result = null;
    try {
      PutObjectResult putObjectResult = ossClient.putObject(bucket, key, inputStream, metadata);
      result = new OssFile(putObjectResult.getETag());
      result.setUrl(endpoint + Constant.SLASH + bucket + Constant.SLASH + key);
      result.setSize(metadata.getContentLength());
      result.setContentType(metadata.getContentType());
    } catch (OSSException e) {
      result = new OssFile(e.getErrorCode(), e.getMessage());
View Full Code Here

TOP

Related Classes of com.aliyun.openservices.oss.model.PutObjectResult

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.