StacClient.CreateCollectionAssetAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Overloads
| Name | Description |
|---|---|
| CreateCollectionAssetAsync(String, StacAssetData, CancellationToken) |
Create a new asset in the Collection metadata and write the associated file to managed storage. |
| CreateCollectionAssetAsync(String, RequestContent, String, RequestContext) |
[Protocol Method] Create a new asset in the Collection metadata and write the associated file to managed storage.
|
CreateCollectionAssetAsync(String, StacAssetData, CancellationToken)
- Source:
- StacClient.cs
Create a new asset in the Collection metadata and write the associated file to managed storage.
public virtual System.Threading.Tasks.Task<Azure.Response<Azure.Analytics.PlanetaryComputer.StacCollection>> CreateCollectionAssetAsync(string collectionId, Azure.Analytics.PlanetaryComputer.StacAssetData body, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateCollectionAssetAsync : string * Azure.Analytics.PlanetaryComputer.StacAssetData * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Analytics.PlanetaryComputer.StacCollection>>
override this.CreateCollectionAssetAsync : string * Azure.Analytics.PlanetaryComputer.StacAssetData * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.Response<Azure.Analytics.PlanetaryComputer.StacCollection>>
Public Overridable Function CreateCollectionAssetAsync (collectionId As String, body As StacAssetData, Optional cancellationToken As CancellationToken = Nothing) As Task(Of Response(Of StacCollection))
Parameters
- collectionId
- String
STAC Collection ID.
- body
- StacAssetData
Multi-part form data.
- cancellationToken
- CancellationToken
The cancellation token that can be used to cancel the operation.
Returns
Exceptions
collectionId or body is null.
collectionId is an empty string, and was expected to be non-empty.
Service returned a non-success status code.
Applies to
CreateCollectionAssetAsync(String, RequestContent, String, RequestContext)
- Source:
- StacClient.cs
[Protocol Method] Create a new asset in the Collection metadata and write the associated file to managed storage.
- This protocol method allows explicit creation of the request and processing of the response for advanced scenarios.
public virtual System.Threading.Tasks.Task<Azure.Response> CreateCollectionAssetAsync(string collectionId, Azure.Core.RequestContent content, string contentType, Azure.RequestContext context = default);
abstract member CreateCollectionAssetAsync : string * Azure.Core.RequestContent * string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
override this.CreateCollectionAssetAsync : string * Azure.Core.RequestContent * string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function CreateCollectionAssetAsync (collectionId As String, content As RequestContent, contentType As String, Optional context As RequestContext = Nothing) As Task(Of Response)
Parameters
- collectionId
- String
STAC Collection ID.
- content
- RequestContent
The content to send as the body of the request.
- contentType
- String
The contentType to use which has the multipart/form-data boundary.
- context
- RequestContext
The request options, which can override default behaviors of the client pipeline on a per-call basis.
Returns
The response returned from the service.
Exceptions
collectionId, content or contentType is null.
collectionId or contentType is an empty string, and was expected to be non-empty.
Service returned a non-success status code.