コード例 #1
0
        /// <summary>Snippet for DeleteLogMetric</summary>
        public void DeleteLogMetric()
        {
            // Snippet: DeleteLogMetric(MetricNameOneof,CallSettings)
            // Create client
            MetricsServiceV2Client metricsServiceV2Client = MetricsServiceV2Client.Create();
            // Initialize request argument(s)
            MetricNameOneof metricName = MetricNameOneof.From(new MetricName("[PROJECT]", "[METRIC]"));

            // Make the request
            metricsServiceV2Client.DeleteLogMetric(metricName);
            // End snippet
        }
コード例 #2
0
        /// <summary>Snippet for DeleteLogMetric</summary>
        public void DeleteLogMetric()
        {
            // Snippet: DeleteLogMetric(string, CallSettings)
            // Create client
            MetricsServiceV2Client metricsServiceV2Client = MetricsServiceV2Client.Create();
            // Initialize request argument(s)
            string metricName = "projects/[PROJECT]/metrics/[METRIC]";

            // Make the request
            metricsServiceV2Client.DeleteLogMetric(metricName);
            // End snippet
        }
コード例 #3
0
        /// <summary>Snippet for DeleteLogMetric</summary>
        public void DeleteLogMetricResourceNames()
        {
            // Snippet: DeleteLogMetric(LogMetricName, CallSettings)
            // Create client
            MetricsServiceV2Client metricsServiceV2Client = MetricsServiceV2Client.Create();
            // Initialize request argument(s)
            LogMetricName metricName = LogMetricName.FromProjectMetric("[PROJECT]", "[METRIC]");

            // Make the request
            metricsServiceV2Client.DeleteLogMetric(metricName);
            // End snippet
        }
コード例 #4
0
        public void DeleteLogMetric()
        {
            // Snippet: DeleteLogMetric(string,CallSettings)
            // Create client
            MetricsServiceV2Client metricsServiceV2Client = MetricsServiceV2Client.Create();
            // Initialize request argument(s)
            string formattedMetricName = MetricsServiceV2Client.FormatMetricName("[PROJECT]", "[METRIC]");

            // Make the request
            metricsServiceV2Client.DeleteLogMetric(formattedMetricName);
            // End snippet
        }
コード例 #5
0
        /// <summary>Snippet for DeleteLogMetric</summary>
        public void DeleteLogMetric_RequestObject()
        {
            // Snippet: DeleteLogMetric(DeleteLogMetricRequest,CallSettings)
            // Create client
            MetricsServiceV2Client metricsServiceV2Client = MetricsServiceV2Client.Create();
            // Initialize request argument(s)
            DeleteLogMetricRequest request = new DeleteLogMetricRequest
            {
                MetricNameAsMetricNameOneof = MetricNameOneof.From(new MetricName("[PROJECT]", "[METRIC]")),
            };

            // Make the request
            metricsServiceV2Client.DeleteLogMetric(request);
            // End snippet
        }