Package org.jets3t.service.model

Examples of org.jets3t.service.model.S3Bucket


        }
    }

    private void displayAclModificationDialog() {
        final HyperlinkActivatedListener hyperlinkListener = this;
        final S3Bucket selectedBucket = currentSelectedBucket;

        runInBackgroundThread(new Runnable() {
            public void run() {
                final S3Object[] selectedObjects = getSelectedObjects();
View Full Code Here


    protected StorageBucket newBucket() {
        if (isGoogleStorageMode) {
            return new GSBucket();
        } else {
            return new S3Bucket();
        }
    }
View Full Code Here

    /**
     * Displays the currently selected bucket's properties in the dialog {@link ItemPropertiesDialog}.
     */
    private void listBucketProperties() {
        final S3Bucket selectedBucket = currentSelectedBucket;

        if (selectedBucket.getAcl() == null || !selectedBucket.isLocationKnown()) {
            // Retrieve all a bucket's details before displaying the summary.
            runInBackgroundThread(new Runnable() {
                public void run() {
                    startProgressDialog("Retrieving details for bucket " + selectedBucket.getName());
                    try {
                        try {
                            if (selectedBucket.getAcl() == null) {
                                selectedBucket.setAcl(
                                    s3ServiceMulti.getS3Service().getBucketAcl(
                                        selectedBucket));
                            }
                            if (!selectedBucket.isLocationKnown()) {
                                selectedBucket.setLocation(
                                    s3ServiceMulti.getS3Service().getBucketLocation(
                                        selectedBucket.getName()));
                            }
                            if (!selectedBucket.isRequesterPaysKnown()) {
                                selectedBucket.setRequesterPays(
                                    s3ServiceMulti.getS3Service().isRequesterPaysBucket(
                                        selectedBucket.getName()));
                            }
                        } catch (S3ServiceException e) {
                            // Retrieving details for a third-party bucket will
                            // often fail when ACL or Location is retrieved,
                            // ignore these failures.
View Full Code Here

        try {
            StorageBucket newBucket = null;
            String targetLocation = null;
            if (TARGET_SERVICE_S3.equals(getTargetService())) {
                targetLocation = S3Bucket.LOCATION_US_WEST;
                newBucket = new S3Bucket(bucketName, targetLocation);
            } else {
                targetLocation = GSBucket.LOCATION_EUROPE;
                newBucket = new GSBucket(bucketName, targetLocation);
            }
            service.createBucket(newBucket);
View Full Code Here

            assertAuthenticatedConnection("Get or Create Bucket with location");
        } catch (ServiceException se) {
            throw new S3ServiceException(se);
        }

        S3Bucket bucket = getBucket(bucketName);
        if (bucket == null) {
            // Bucket does not exist in this user's account, create it.
            bucket = createBucket(new S3Bucket(bucketName, location));
        }
        return bucket;
    }
View Full Code Here

        return new XmlResponsesSaxParser(getJetS3tProperties(), false);
    }

    @Override
    protected StorageBucket newBucket() {
        return new S3Bucket();
    }
View Full Code Here

    this.s3Service = s3Service;
    this.metrics = metrics;
    this.uploadMetadata = uploadMetadata;
    this.fileDirectory = uploadMetadata.getDirectory();
    this.pathMatcher = fileSystem.getPathMatcher("glob:" + uploadMetadata.getFileGlob());
    this.s3Bucket = new S3Bucket(uploadMetadata.getS3Bucket());
    this.metadataPath = metadataPath;
    this.logIdentifier = String.format("[%s]", metadataPath.getFileName());
  }
View Full Code Here

      if (e.getCause() instanceof IOException) {
        throw (IOException) e.getCause();
      }
      throw new S3Exception(e);
    }
    bucket = new S3Bucket(uri.getHost());
  }
View Full Code Here

      if (e.getCause() instanceof IOException) {
        throw (IOException) e.getCause();
      }
      throw new S3Exception(e);
    }
    bucket = new S3Bucket(uri.getHost());

    this.bufferSize = conf.getInt("io.file.buffer.size", 4096);
  }
View Full Code Here

      if (e.getCause() instanceof IOException) {
        throw (IOException) e.getCause();
      }
      throw new S3Exception(e);
    }
    bucket = new S3Bucket(uri.getHost());
  }
View Full Code Here

TOP

Related Classes of org.jets3t.service.model.S3Bucket

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.