Tabnine Logo
StorageService.assertAuthenticatedConnection
Code IndexAdd Tabnine to your IDE (free)

How to use
assertAuthenticatedConnection
method
in
org.jets3t.service.StorageService

Best Java code snippets using org.jets3t.service.StorageService.assertAuthenticatedConnection (Showing top 8 results out of 315)

origin: net.java.dev.jets3t/jets3t

/**
 * Returns the owner of an account, using information available in the
 * bucket listing response.
 * <p>
 * This method cannot be performed by anonymous services, and will fail with an exception
 * if the service is not authenticated.
 *
 * @return
 * the owner of the account.
 * @throws ServiceException
 */
public StorageOwner getAccountOwner() throws ServiceException {
  assertAuthenticatedConnection("List all buckets to find account owner");
  return getAccountOwnerImpl();
}
origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jets3t

/**
 * Returns the owner of an account, using information available in the
 * bucket listing response.
 * <p>
 * This method cannot be performed by anonymous services, and will fail with an exception
 * if the service is not authenticated.
 *
 * @return
 * the owner of the account.
 * @throws ServiceException
 */
public StorageOwner getAccountOwner() throws ServiceException {
  assertAuthenticatedConnection("List all buckets to find account owner");
  return getAccountOwnerImpl();
}
origin: net.java.dev.jets3t/jets3t

/**
 * Returns a bucket in your account by listing all your buckets
 * (using {@link #listAllBuckets()}), and looking for the named bucket in
 * this list.
 * <p>
 * This method cannot be performed by anonymous services.
 *
 * @param bucketName
 * @return
 * the bucket in your account, or null if you do not own the named bucket.
 *
 * @throws ServiceException
 */
public StorageBucket getBucket(String bucketName) throws ServiceException {
  assertAuthenticatedConnection("Get Bucket");
  // List existing buckets and return the named bucket if it exists.
  StorageBucket[] existingBuckets = listAllBuckets();
  for (int i = 0; i < existingBuckets.length; i++) {
    if (existingBuckets[i].getName().equals(bucketName)) {
      return existingBuckets[i];
    }
  }
  return null;
}
origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jets3t

/**
 * Returns a bucket in your account by listing all your buckets
 * (using {@link #listAllBuckets()}), and looking for the named bucket in
 * this list.
 * <p>
 * This method cannot be performed by anonymous services.
 *
 * @param bucketName
 * @return
 * the bucket in your account, or null if you do not own the named bucket.
 *
 * @throws ServiceException
 */
public StorageBucket getBucket(String bucketName) throws ServiceException {
  assertAuthenticatedConnection("Get Bucket");
  // List existing buckets and return the named bucket if it exists.
  StorageBucket[] existingBuckets = listAllBuckets();
  for (int i = 0; i < existingBuckets.length; i++) {
    if (existingBuckets[i].getName().equals(bucketName)) {
      return existingBuckets[i];
    }
  }
  return null;
}
origin: net.java.dev.jets3t/jets3t

/**
 * Lists the buckets belonging to the service user.
 * <p>
 * This method cannot be performed by anonymous services, and will fail with an exception
 * if the service is not authenticated.
 *
 * @return
 * the list of buckets owned by the service user.
 * @throws ServiceException
 */
public StorageBucket[] listAllBuckets() throws ServiceException {
  assertAuthenticatedConnection("List all buckets");
  StorageBucket[] buckets = listAllBucketsImpl();
  MxDelegate.getInstance().registerStorageBucketMBeans(buckets);
  return buckets;
}
origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jets3t

/**
 * Lists the buckets belonging to the service user.
 * <p>
 * This method cannot be performed by anonymous services, and will fail with an exception
 * if the service is not authenticated.
 *
 * @return
 * the list of buckets owned by the service user.
 * @throws ServiceException
 */
public StorageBucket[] listAllBuckets() throws ServiceException {
  assertAuthenticatedConnection("List all buckets");
  StorageBucket[] buckets = listAllBucketsImpl();
  MxDelegate.getInstance().registerStorageBucketMBeans(buckets);
  return buckets;
}
origin: net.java.dev.jets3t/jets3t

String[] ifNoneMatchTags) throws ServiceException
assertAuthenticatedConnection("copyObject");
Map<String, Object> destinationMetadata =
  replaceMetadata ? destinationObject.getModifiableMetadata() : null;
origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jets3t

String[] ifNoneMatchTags) throws ServiceException
assertAuthenticatedConnection("copyObject");
Map<String, Object> destinationMetadata =
  replaceMetadata ? destinationObject.getModifiableMetadata() : null;
org.jets3t.serviceStorageServiceassertAuthenticatedConnection

Javadoc

Throws an exception if this service is anonymous (that is, it was created without an ProviderCredentials object representing a user account.

Popular methods of StorageService

  • getObject
    Returns an object representing the details and data of an item that meets any given preconditions.Im
  • getObjectDetails
    Returns an object representing the details of an item that meets any given preconditions. The object
  • putObject
    Puts an object inside an existing bucket, creating a new object or overwriting an existing one with
  • assertValidBucket
    Throws an exception if a bucket is null or contains a null/empty name.
  • assertValidObject
    Throws an exception if an object is null or contains a null/empty key.
  • copyObject
    Copy an object. You can copy an object within a single bucket or between buckets, and can optionally
  • copyObjectImpl
    Copy an object within your account. Copies within a single bucket or between buckets, and optionally
  • createBucket
    Create a bucket with the Access Control List settings of the bucket object (if any).Caution: Perform
  • createBucketImpl
  • deleteBucketImpl
  • deleteObject
    Deletes an object from a bucket. This method can be performed by anonymous services. Anonymous servi
  • deleteObjectImpl
  • deleteObject,
  • deleteObjectImpl,
  • getAccountOwnerImpl,
  • getBucket,
  • getBucketAclImpl,
  • getHttpsOnly,
  • getJetS3tProperties,
  • getObjectAcl,
  • getObjectAclImpl

Popular in Java

  • Creating JSON documents from java classes using gson
  • scheduleAtFixedRate (Timer)
  • compareTo (BigDecimal)
  • getResourceAsStream (ClassLoader)
  • EOFException (java.io)
    Thrown when a program encounters the end of a file or stream during an input operation.
  • Permission (java.security)
    Legacy security code; do not use.
  • TimeZone (java.util)
    TimeZone represents a time zone offset, and also figures out daylight savings. Typically, you get a
  • Notification (javax.management)
  • JTextField (javax.swing)
  • Options (org.apache.commons.cli)
    Main entry-point into the library. Options represents a collection of Option objects, which describ
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now