ReceivedSharesClient.GetReceivedShareAsync(String, RequestContext) Methode
Definition
Wichtig
Einige Informationen beziehen sich auf Vorabversionen, die vor dem Release ggf. grundlegend überarbeitet werden. Microsoft übernimmt hinsichtlich der hier bereitgestellten Informationen keine Gewährleistungen, seien sie ausdrücklich oder konkludent.
[Protokollmethode] Abrufen einer empfangenen Freigabe nach eindeutiger ID.
- Diese Protokollmethode ermöglicht die explizite Erstellung der Anforderung und Verarbeitung der Antwort für erweiterte Szenarien.
public virtual System.Threading.Tasks.Task<Azure.Response> GetReceivedShareAsync (string receivedShareId, Azure.RequestContext context = default);
abstract member GetReceivedShareAsync : string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
override this.GetReceivedShareAsync : string * Azure.RequestContext -> System.Threading.Tasks.Task<Azure.Response>
Public Overridable Function GetReceivedShareAsync (receivedShareId As String, Optional context As RequestContext = Nothing) As Task(Of Response)
Parameter
- receivedShareId
- String
ID der empfangenen Freigabe.
- context
- RequestContext
Der Anforderungskontext, der das Standardverhalten der Clientpipeline pro Aufruf außer Kraft setzen kann.
Gibt zurück
Die vom Dienst zurückgegebene Antwort.
Ausnahmen
receivedShareId
ist NULL.
receivedShareId
ist eine leere Zeichenfolge und wurde erwartet, dass sie nicht leer ist.
Der Dienst hat einen nicht erfolgreichen status Code zurückgegeben.
Beispiele
In diesem Beispiel wird gezeigt, wie GetReceivedShareAsync mit den erforderlichen Parametern aufgerufen und das Ergebnis analysiert wird.
var credential = new DefaultAzureCredential();
var endpoint = new Uri("<https://my-service.azure.com>");
var client = new ReceivedSharesClient(endpoint, credential);
Response response = await client.GetReceivedShareAsync("<receivedShareId>");
JsonElement result = JsonDocument.Parse(response.ContentStream).RootElement;
Console.WriteLine(result.GetProperty("shareKind").ToString());
Console.WriteLine(result.GetProperty("id").ToString());
Console.WriteLine(result.GetProperty("type").ToString());
Hinweise
Abrufen einer empfangenen Freigabe
Im Folgenden finden Sie das JSON-Schema für die Antwortnutzlast.
Antworttext:
InPlaceReceivedShare
Schema fürInPlaceReceivedShare
:{
properties: {
assetLocation: string, # Optional. Location of the shared Asset.
assetStoreKind: "AdlsGen2Account" | "BlobAccount", # Optional. The types of asset.
createdAt: string (ISO 8601 Format), # Optional. Time at which the received share was created. Represented in the standard date-time format as defined by [RFC 3339](https://www.rfc-editor.org/rfc/rfc3339)
displayName: string, # Optional. Received Share Name
expirationDate: string (ISO 8601 Format), # Optional. The expiration date of the received share. Represented in the standard date-time format as defined by [RFC 3339](https://www.rfc-editor.org/rfc/rfc3339)
receiverEmail: string, # Optional. Email of the user/receiver who received the sent share invitation
receiverName: string, # Optional. Name of the user/receiver who received the sent share invitation
receiverTenantName: string, # Optional. Tenant name of the user/receiver who received the sent share invitation
senderEmail: string, # Optional. Email of the sender who created the sent share invitation
senderName: string, # Optional. Name of the sender who created the sent share invitation
senderTenantName: string, # Optional. Tenant name of the sender who created the sent share invitation
sentShareDescription: string, # Optional. Share description.
sharedAt: string (ISO 8601 Format), # Optional. Time at which the sent share was shared. Represented in the standard date-time format as defined by [RFC 3339](https://www.rfc-editor.org/rfc/rfc3339)
shareStatus: "Detached" | "Attached", # Optional. Share status.
sink: {
storeKind: "AdlsGen2Account" | "BlobAccount", # Required. The types of asset.
storeReference: {
referenceName: string, # Optional. Reference name for resource associated with the sink or artifact.
type: "ArmResourceReference", # Optional. Defines the type of resource being shared
}, # Required. A Store Reference for an artifact or sink.
}, # Optional. Holds details on the destination of the mapped artifact
state: "Unknown" | "Succeeded" | "Creating" | "Deleting" | "Moving" | "Failed", # Optional. State of the resource
}, # Required. Properties of in place received share.
shareKind: InPlace, # Required. Defines the supported types for share.
id: string, # Optional. The unique id of the resource.
type: string, # Optional. Type of the resource.
}
Gilt für:
Azure SDK for .NET
Feedback
https://aka.ms/ContentUserFeedback.
Bald verfügbar: Im Laufe des Jahres 2024 werden wir GitHub-Issues stufenweise als Feedbackmechanismus für Inhalte abbauen und durch ein neues Feedbacksystem ersetzen. Weitere Informationen finden Sie unterFeedback senden und anzeigen für