< Summary

Class:Microsoft.Azure.OperationalInsights.Models.ApiPreferences
Assembly:Microsoft.Azure.OperationalInsights
File(s):C:\Git\azure-sdk-for-net\sdk\operationalinsights\Microsoft.Azure.OperationalInsights\src\Customized\Models\ApiPreferences.cs
Covered lines:0
Uncovered lines:11
Coverable lines:11
Total lines:39
Line coverage:0% (0 of 11)
Covered branches:0
Total branches:6
Branch coverage:0% (0 of 6)

Metrics

MethodCyclomatic complexity Line coverage Branch coverage
get_IncludeRender()-0%100%
get_IncludeStatistics()-0%100%
get_Wait()-0%100%
ToString()-0%0%

File(s)

C:\Git\azure-sdk-for-net\sdk\operationalinsights\Microsoft.Azure.OperationalInsights\src\Customized\Models\ApiPreferences.cs

#LineLine coverage
 1namespace Microsoft.Azure.OperationalInsights.Models
 2{
 3    public class ApiPreferences
 4    {
 5        /// <summary>
 6        /// See https://dev.loganalytics.io/documentation/Using-the-API/RequestOptions
 7        /// </summary>
 08        public bool IncludeRender { get; set; } = false;
 9
 10        /// <summary>
 11        ///  See https://dev.loganalytics.io/documentation/Using-the-API/RequestOptions
 12        /// </summary>
 013        public bool IncludeStatistics { get; set; } = false;
 14
 15        /// <summary>
 16        /// Puts an upper bound on the amount of time the server will spend processing the query. See: https://dev.logan
 17        /// </summary>
 018        public int Wait { get; set; } = int.MinValue;
 19
 20        public override string ToString()
 21        {
 022            var pref = "response-v1=true";
 023            if (IncludeRender)
 24            {
 025                pref += ",include-render=true";
 26            }
 027            if (IncludeStatistics)
 28            {
 029                pref += ",include-statistics=true";
 30            }
 031            if (Wait != int.MinValue)
 32            {
 033                pref += $",wait={Wait}";
 34            }
 35
 036            return pref;
 37        }
 38    }
 39}