microsoft-azure-storage/src/com/microsoft/azure/storage/file/CloudFile.java
public void uploadFromByteArray(final byte[] buffer, final int offset, final int length,
            final AccessCondition accessCondition, FileRequestOptions options, OperationContext opContext)
            throws StorageException, IOException, URISyntaxException {
        ByteArrayInputStream inputStream = new ByteArrayInputStream(buffer, offset, length);
        this.upload(inputStream, length, accessCondition, options, opContext);
        inputStream.close();
    }
public void uploadFromByteArray(final byte[] buffer, final int offset, final int length,
            final AccessCondition accessCondition, FileRequestOptions options, OperationContext opContext)
            throws StorageException, IOException, URISyntaxException {
        ByteArrayInputStream inputStream = new ByteArrayInputStream(buffer, offset, length);
        this.upload(inputStream, length, accessCondition, options, opContext);
        inputStream.close();
    }
public void uploadFromByteArray ( final byte [ ] buffer , final int offset , final int length , final AccessCondition accessCondition , FileRequestOptions options , OperationContext opContext ) throws StorageException , IOException , URISyntaxException { ByteArrayInputStream inputStream = new ByteArrayInputStream ( buffer , offset , length ) ; this . upload ( inputStream , length , accessCondition , options , opContext ) ; inputStream . close ( ) ; }
Uploads a file from data in a byte array. If the file already exists on the service, it will be overwritten.

@param buffer
A <code>byte</code> array which represents the data to write to the file.
@param offset
A <code>int</code> which represents the offset of the byte array from which to start the data upload.
@param length
An <code>int</code> which represents the number of bytes to upload from the input buffer.
@param accessCondition
An {@link AccessCondition} object that represents the access conditions for the file.
@param options
A {@link FileRequestOptions} object that specifies any additional options for the request. Specifying
<code>null</code> will use the default request options from the associated service client (
{@link CloudFileClient}).
@param opContext
An {@link OperationContext} object that represents the context for the current operation. This object
is used to track requests to the storage service, and to provide additional runtime information about
the operation.

@throws StorageException
If a storage service error occurred.
@throws IOException
@throws URISyntaxException
Uploads a file from data in a byte array . If the file already exists on the service it will be overwritten .