/// <summary>Snippet for UpdateVersion</summary>
        public void UpdateVersionRequestObject()
        {
            // Snippet: UpdateVersion(UpdateVersionRequest, CallSettings)
            // Create client
            VersionsClient versionsClient = VersionsClient.Create();
            // Initialize request argument(s)
            UpdateVersionRequest request = new UpdateVersionRequest
            {
                Name       = "",
                Version    = new gcav::Version(),
                UpdateMask = new FieldMask(),
            };
            // Make the request
            Operation <gcav::Version, OperationMetadataV1> response = versionsClient.UpdateVersion(request);

            // Poll until the returned long-running operation is complete
            Operation <gcav::Version, OperationMetadataV1> completedResponse = response.PollUntilCompleted();
            // Retrieve the operation result
            gcav::Version result = completedResponse.Result;

            // Or get the name of the operation
            string operationName = response.Name;
            // This name can be stored, then the long-running operation retrieved later by name
            Operation <gcav::Version, OperationMetadataV1> retrievedResponse = versionsClient.PollOnceUpdateVersion(operationName);

            // Check if the retrieved long-running operation has completed
            if (retrievedResponse.IsCompleted)
            {
                // If it has completed, then access the result
                gcav::Version retrievedResult = retrievedResponse.Result;
            }
            // End snippet
        }
Exemple #2
0
 /// <summary>Snippet for UpdateVersion</summary>
 public void UpdateVersion()
 {
     // Snippet: UpdateVersion(Version, FieldMask, CallSettings)
     // Create client
     VersionsClient versionsClient = VersionsClient.Create();
     // Initialize request argument(s)
     gcdcv::Version version    = new gcdcv::Version();
     FieldMask      updateMask = new FieldMask();
     // Make the request
     gcdcv::Version response = versionsClient.UpdateVersion(version, updateMask);
     // End snippet
 }
Exemple #3
0
 /// <summary>Snippet for UpdateVersion</summary>
 public void UpdateVersionRequestObject()
 {
     // Snippet: UpdateVersion(UpdateVersionRequest, CallSettings)
     // Create client
     VersionsClient versionsClient = VersionsClient.Create();
     // Initialize request argument(s)
     UpdateVersionRequest request = new UpdateVersionRequest
     {
         Version    = new gcdcv::Version(),
         UpdateMask = new FieldMask(),
     };
     // Make the request
     gcdcv::Version response = versionsClient.UpdateVersion(request);
     // End snippet
 }