Edit

Share via


GitHttpClientBase.GetBlobContentAsync Method

Definition

Overloads

GetBlobContentAsync(String, String, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

GetBlobContentAsync(String, String, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

GetBlobContentAsync(String, Guid, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

GetBlobContentAsync(Guid, String, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

GetBlobContentAsync(String, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

GetBlobContentAsync(Guid, Guid, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

GetBlobContentAsync(Guid, String, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

GetBlobContentAsync(Guid, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

GetBlobContentAsync(String, Guid, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

GetBlobContentAsync(Guid, Guid, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

GetBlobContentAsync(String, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

GetBlobContentAsync(Guid, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

GetBlobContentAsync(String, String, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(string project, string repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetBlobContentAsync : string * string * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
override this.GetBlobContentAsync : string * string * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
String

Project ID or project name

repositoryId
String

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(String, String, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(string project, string repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, Nullable<bool> resolveLfs = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
override this.GetBlobContentAsync : string * string * string * Nullable<bool> * string * Nullable<bool> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
String

Project ID or project name

repositoryId
String

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

resolveLfs
Nullable<Boolean>

If true, try to resolve a blob to its LFS contents, if it's an LFS pointer file. Only compatible with octet-stream Accept headers or $format types

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(String, Guid, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(string project, Guid repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, Nullable<bool> resolveLfs = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
override this.GetBlobContentAsync : string * Guid * string * Nullable<bool> * string * Nullable<bool> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
String

Project ID or project name

repositoryId
Guid

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

resolveLfs
Nullable<Boolean>

If true, try to resolve a blob to its LFS contents, if it's an LFS pointer file. Only compatible with octet-stream Accept headers or $format types

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(Guid, String, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(Guid project, string repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, Nullable<bool> resolveLfs = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
override this.GetBlobContentAsync : Guid * string * string * Nullable<bool> * string * Nullable<bool> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
Guid

Project ID

repositoryId
String

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

resolveLfs
Nullable<Boolean>

If true, try to resolve a blob to its LFS contents, if it's an LFS pointer file. Only compatible with octet-stream Accept headers or $format types

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(String, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(string repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, Nullable<bool> resolveLfs = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
override this.GetBlobContentAsync : string * string * Nullable<bool> * string * Nullable<bool> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

repositoryId
String

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

resolveLfs
Nullable<Boolean>

If true, try to resolve a blob to its LFS contents, if it's an LFS pointer file. Only compatible with octet-stream Accept headers or $format types

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(Guid, Guid, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(Guid project, Guid repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, Nullable<bool> resolveLfs = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
override this.GetBlobContentAsync : Guid * Guid * string * Nullable<bool> * string * Nullable<bool> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
Guid

Project ID

repositoryId
Guid

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

resolveLfs
Nullable<Boolean>

If true, try to resolve a blob to its LFS contents, if it's an LFS pointer file. Only compatible with octet-stream Accept headers or $format types

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(Guid, String, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(Guid project, string repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetBlobContentAsync : Guid * string * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
override this.GetBlobContentAsync : Guid * string * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
Guid

Project ID

repositoryId
String

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(Guid, String, Nullable<Boolean>, String, Nullable<Boolean>, Object, CancellationToken)

[Preview API] Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(Guid repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, Nullable<bool> resolveLfs = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
override this.GetBlobContentAsync : Guid * string * Nullable<bool> * string * Nullable<bool> * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

repositoryId
Guid

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

resolveLfs
Nullable<Boolean>

If true, try to resolve a blob to its LFS contents, if it's an LFS pointer file. Only compatible with octet-stream Accept headers or $format types

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(String, Guid, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(string project, Guid repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetBlobContentAsync : string * Guid * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
override this.GetBlobContentAsync : string * Guid * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
String

Project ID or project name

repositoryId
Guid

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(Guid, Guid, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(Guid project, Guid repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetBlobContentAsync : Guid * Guid * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
override this.GetBlobContentAsync : Guid * Guid * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

project
Guid

Project ID

repositoryId
Guid

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(String, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(string repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetBlobContentAsync : string * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
override this.GetBlobContentAsync : string * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

repositoryId
String

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to

GetBlobContentAsync(Guid, String, Nullable<Boolean>, String, Object, CancellationToken)

Get a single blob.

public virtual System.Threading.Tasks.Task<System.IO.Stream> GetBlobContentAsync(Guid repositoryId, string sha1, Nullable<bool> download = null, string fileName = null, object userState = null, System.Threading.CancellationToken cancellationToken = null);
abstract member GetBlobContentAsync : Guid * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>
override this.GetBlobContentAsync : Guid * string * Nullable<bool> * string * obj * System.Threading.CancellationToken -> System.Threading.Tasks.Task<System.IO.Stream>

Parameters

repositoryId
Guid

The name or ID of the repository.

sha1
String

SHA1 hash of the file. You can get the SHA1 of a file using the "Git/Items/Get Item" endpoint.

download
Nullable<Boolean>

If true, prompt for a download rather than rendering in a browser. Note: this value defaults to true if $format is zip

fileName
String

Provide a fileName to use for a download.

userState
Object
cancellationToken
CancellationToken

The cancellation token to cancel operation.

Returns

Applies to