Tabnine Logo
CloudBlob.download
Code IndexAdd Tabnine to your IDE (free)

How to use
download
method
in
com.microsoft.azure.storage.blob.CloudBlob

Best Java code snippets using com.microsoft.azure.storage.blob.CloudBlob.download (Showing top 19 results out of 315)

origin: apache/nifi

  blob.download(os, null, null, operationContext);
} catch (StorageException e) {
  storedException.set(e);
origin: Azure/azure-storage-android

blob.download(new ByteArrayOutputStream(), null, null, sendingRequestEventContext);
assertEquals(2, callList.size());
origin: stackoverflow.com

 OutputStream os = ...; // get the OutputStream from the HTTP Response
CloudBlobContainer container = blobClient.getContainerReference("<container-name>");
CloudBlob blob = getBlockBlobReference("<blob-name>");
blob.download(os)
origin: Azure/azure-storage-android

    null)) {
  final ByteArrayOutputStream outStream = new ByteArrayOutputStream(length);
  ((CloudBlob) blob).download(outStream);
blobSnapshot.download(outStream);
byte[] retrievedBuff = outStream.toByteArray();
assertEquals(length, retrievedBuff.length);
origin: com.microsoft.azure/azure-storage

/**
 * Downloads the contents of a blob to a stream.
 *
 * @param outStream
 *            An <code>{@link OutputStream}</code> object that represents the target stream.
 * @throws StorageException
 *             If a storage service error occurred.
 */
@DoesServiceRequest
public final void download(final OutputStream outStream) throws StorageException {
  this.download(outStream, null /* accessCondition */, null /* options */, null /* opContext */);
}
origin: Azure/azure-storage-android

  final ByteArrayOutputStream outStream = new ByteArrayOutputStream(
      length);
  ((CloudBlob) blob).download(outStream);
blobSnapshot.download(outStream);
byte[] retrievedBuff = outStream.toByteArray();
assertEquals(length, retrievedBuff.length);
origin: Azure/azure-storage-android

/**
 * Downloads the contents of a blob to a stream.
 *
 * @param outStream
 *            An <code>{@link OutputStream}</code> object that represents the target stream.
 * @throws StorageException
 *             If a storage service error occurred.
 */
@DoesServiceRequest
public final void download(final OutputStream outStream) throws StorageException {
  this.download(outStream, null /* accessCondition */, null /* options */, null /* opContext */);
}
origin: Azure/azure-storage-android

    null)) {
  final ByteArrayOutputStream outStream = new ByteArrayOutputStream(length);
  ((CloudBlob) blob).download(outStream);
blobSnapshot.download(outStream);
byte[] retrievedBuff = outStream.toByteArray();
assertEquals(length, retrievedBuff.length);
origin: org.talend.components/components-azurestorage

public void download(final CloudBlob blob, final OutputStream outStream) throws StorageException {
  blob.download(outStream, null, null, AzureStorageUtils.getTalendOperationContext());
}
origin: Talend/components

public void download(final CloudBlob blob, final OutputStream outStream) throws StorageException {
  blob.download(outStream, null, null, AzureStorageUtils.getTalendOperationContext());
}
origin: apache/jackrabbit-oak

public static void readBufferFully(CloudBlob blob, Buffer buffer) throws IOException {
  try {
    blob.download(new ByteBufferOutputStream(buffer));
    buffer.flip();
  } catch (StorageException e) {
    throw new IOException(e);
  }
}
origin: org.apache.jackrabbit/oak-segment-azure

public static void readBufferFully(CloudBlob blob, Buffer buffer) throws IOException {
  try {
    blob.download(new ByteBufferOutputStream(buffer));
    buffer.flip();
  } catch (StorageException e) {
    throw new IOException(e);
  }
}
origin: com.microsoft.azure/azure-storage

OutputStream outputStream = new BufferedOutputStream(new FileOutputStream(path));
try {
  this.download(outputStream, accessCondition, options, opContext);
  outputStream.close();
origin: Azure/azure-storage-android

OutputStream outputStream = new BufferedOutputStream(new FileOutputStream(path));
try {
  this.download(outputStream, accessCondition, options, opContext);
  outputStream.close();
origin: stackoverflow.com

blob.download(new FileOutputStream("your storage location" + blob.getName() + ".jpeg"));
Log.d(" blob.getName()=", " " + blob.getName());
break;
origin: org.jgroups/jgroups-azure

@Override
protected void readAll(final List<Address> members, final String clustername, final Responses responses) {
  if (clustername == null) {
    return;
  }
  String prefix = sanitize(clustername);
  Iterable<ListBlobItem> listBlobItems = containerReference.listBlobs(prefix);
  for (ListBlobItem blobItem : listBlobItems) {
    try {
      // If the item is a blob and not a virtual directory.
      // n.b. what an ugly API this is
      if (blobItem instanceof CloudBlob) {
        CloudBlob blob = (CloudBlob) blobItem;
        ByteArrayOutputStream os = new ByteArrayOutputStream(STREAM_BUFFER_SIZE);
        blob.download(os);
        byte[] pingBytes = os.toByteArray();
        parsePingData(pingBytes, members, responses);
      }
    } catch (Exception t) {
      log.error("Error fetching ping data.");
    }
  }
}
origin: org.jgroups.azure/jgroups-azure

@Override
protected void readAll(final List<Address> members, final String clustername, final Responses responses) {
  if (clustername == null) {
    return;
  }
  String prefix = sanitize(clustername);
  Iterable<ListBlobItem> listBlobItems = containerReference.listBlobs(prefix);
  for (ListBlobItem blobItem : listBlobItems) {
    try {
      // If the item is a blob and not a virtual directory.
      // n.b. what an ugly API this is
      if (blobItem instanceof CloudBlob) {
        CloudBlob blob = (CloudBlob) blobItem;
        ByteArrayOutputStream os = new ByteArrayOutputStream(STREAM_BUFFER_SIZE);
        blob.download(os);
        byte[] pingBytes = os.toByteArray();
        parsePingData(pingBytes, members, responses);
      }
    } catch (Exception t) {
      log.error("Error fetching ping data.");
    }
  }
}
origin: Azure/azure-iot-sdk-java

blob.download(new FileOutputStream(SampleUtils.exportFileLocation + blob.getName()));
origin: Microsoft/azure-tools-for-java

public void downloadBlobFileContent(@NotNull String connectionString,
                  @NotNull BlobFile blobFile,
                  @NotNull OutputStream content)
    throws AzureCmdException {
  try {
    CloudBlobClient client = getCloudBlobClient(connectionString);
    String containerName = blobFile.getContainerName();
    CloudBlobContainer container = client.getContainerReference(containerName);
    CloudBlob blob = getCloudBlob(container, blobFile);
    blob.download(content);
  } catch (Throwable t) {
    throw new AzureCmdException("Error downloading the Blob File content", t);
  }
}
com.microsoft.azure.storage.blobCloudBlobdownload

Javadoc

Downloads the contents of a blob to a stream.

Popular methods of CloudBlob

  • getName
    Returns the name of the blob.
  • deleteIfExists
    Deletes the blob if it exists, using the specified snapshot and request options, and operation conte
  • getProperties
    Returns the blob's properties.
  • downloadAttributes
    Populates a blob's properties and metadata using the specified request options and operation context
  • getUri
    Returns the URI for this blob.
  • getMetadata
    Returns the metadata for the blob.
  • delete
    Deletes the blob using the specified snapshot and request options, and operation context. If a delet
  • acquireLease
    Acquires a new lease on the blob with the specified lease time, proposed lease ID, request options,
  • openInputStream
    Opens a blob input stream to download the blob using the specified request options and operation con
  • releaseLease
    Releases the lease on the blob using the specified request options and operation context.
  • setMetadata
    Sets the metadata for the blob.
  • upload
    Uploads the source stream data to the blob using the specified lease ID, request options, and operat
  • setMetadata,
  • upload,
  • uploadMetadata,
  • downloadToByteArray,
  • exists,
  • startCopy,
  • uploadProperties,
  • downloadRange,
  • downloadRangeToByteArray

Popular in Java

  • Updating database using SQL prepared statement
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • setRequestProperty (URLConnection)
  • requestLocationUpdates (LocationManager)
  • FileOutputStream (java.io)
    An output stream that writes bytes to a file. If the output file exists, it can be replaced or appen
  • InputStream (java.io)
    A readable source of bytes.Most clients will use input streams that read data from the file system (
  • HttpURLConnection (java.net)
    An URLConnection for HTTP (RFC 2616 [http://tools.ietf.org/html/rfc2616]) used to send and receive d
  • GregorianCalendar (java.util)
    GregorianCalendar is a concrete subclass of Calendarand provides the standard calendar used by most
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • From CI to AI: The AI layer in your organization
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