Esempio n. 1
0
        /// <summary>Snippet for DeleteDocumentAsync</summary>
        public async Task DeleteDocumentAsync()
        {
            // Snippet: DeleteDocumentAsync(string, CallSettings)
            // Additional: DeleteDocumentAsync(string, CancellationToken)
            // Create client
            FirestoreClient firestoreClient = await FirestoreClient.CreateAsync();

            // Initialize request argument(s)
            string name = "";
            // Make the request
            await firestoreClient.DeleteDocumentAsync(name);

            // End snippet
        }
        /// <summary>Snippet for DeleteDocumentAsync</summary>
        public async Task DeleteDocumentAsync()
        {
            // Snippet: DeleteDocumentAsync(string,CallSettings)
            // Additional: DeleteDocumentAsync(string,CancellationToken)
            // Create client
            FirestoreClient firestoreClient = await FirestoreClient.CreateAsync();

            // Initialize request argument(s)
            string formattedName = new AnyPathName("[PROJECT]", "[DATABASE]", "[DOCUMENT]", "[ANY_PATH]").ToString();
            // Make the request
            await firestoreClient.DeleteDocumentAsync(formattedName);

            // End snippet
        }
        /// <summary>Snippet for DeleteDocumentAsync</summary>
        public async Task DeleteDocumentAsync_RequestObject()
        {
            // Snippet: DeleteDocumentAsync(DeleteDocumentRequest,CallSettings)
            // Create client
            FirestoreClient firestoreClient = await FirestoreClient.CreateAsync();

            // Initialize request argument(s)
            DeleteDocumentRequest request = new DeleteDocumentRequest
            {
                Name = new AnyPathName("[PROJECT]", "[DATABASE]", "[DOCUMENT]", "[ANY_PATH]").ToString(),
            };
            // Make the request
            await firestoreClient.DeleteDocumentAsync(request);

            // End snippet
        }
Esempio n. 4
0
        /// <summary>Snippet for DeleteDocumentAsync</summary>
        public async Task DeleteDocumentRequestObjectAsync()
        {
            // Snippet: DeleteDocumentAsync(DeleteDocumentRequest, CallSettings)
            // Additional: DeleteDocumentAsync(DeleteDocumentRequest, CancellationToken)
            // Create client
            FirestoreClient firestoreClient = await FirestoreClient.CreateAsync();

            // Initialize request argument(s)
            DeleteDocumentRequest request = new DeleteDocumentRequest
            {
                Name            = "",
                CurrentDocument = new Precondition(),
            };
            // Make the request
            await firestoreClient.DeleteDocumentAsync(request);

            // End snippet
        }