| | 1 | | // <auto-generated> |
| | 2 | | // Copyright (c) Microsoft Corporation. All rights reserved. |
| | 3 | | // Licensed under the MIT License. See License.txt in the project root for |
| | 4 | | // license information. |
| | 5 | | // |
| | 6 | | // Code generated by Microsoft (R) AutoRest Code Generator. |
| | 7 | | // Changes may cause incorrect behavior and will be lost if the code is |
| | 8 | | // regenerated. |
| | 9 | | // </auto-generated> |
| | 10 | |
|
| | 11 | | namespace Microsoft.Azure.CognitiveServices.AnomalyDetector |
| | 12 | | { |
| | 13 | | using Models; |
| | 14 | | using System.Threading; |
| | 15 | | using System.Threading.Tasks; |
| | 16 | |
|
| | 17 | | /// <summary> |
| | 18 | | /// Extension methods for AnomalyDetectorClient. |
| | 19 | | /// </summary> |
| | 20 | | public static partial class AnomalyDetectorClientExtensions |
| | 21 | | { |
| | 22 | | /// <summary> |
| | 23 | | /// Detect anomalies for the entire series in batch. |
| | 24 | | /// </summary> |
| | 25 | | /// <remarks> |
| | 26 | | /// This operation generates a model using an entire series, each point is |
| | 27 | | /// detected with the same model. With this method, points before and after a |
| | 28 | | /// certain point are used to determine whether it is an anomaly. The entire |
| | 29 | | /// detection can give user an overall status of the time series. |
| | 30 | | /// </remarks> |
| | 31 | | /// <param name='operations'> |
| | 32 | | /// The operations group for this extension method. |
| | 33 | | /// </param> |
| | 34 | | /// <param name='body'> |
| | 35 | | /// Time series points and period if needed. Advanced model parameters can also |
| | 36 | | /// be set in the request. |
| | 37 | | /// </param> |
| | 38 | | /// <param name='cancellationToken'> |
| | 39 | | /// The cancellation token. |
| | 40 | | /// </param> |
| | 41 | | public static async Task<EntireDetectResponse> EntireDetectAsync(this IAnomalyDetectorClient operations, Req |
| | 42 | | { |
| 0 | 43 | | using (var _result = await operations.EntireDetectWithHttpMessagesAsync(body, null, cancellationToken).C |
| | 44 | | { |
| 0 | 45 | | return _result.Body; |
| | 46 | | } |
| 0 | 47 | | } |
| | 48 | |
|
| | 49 | | /// <summary> |
| | 50 | | /// Detect anomaly status of the latest point in time series. |
| | 51 | | /// </summary> |
| | 52 | | /// <remarks> |
| | 53 | | /// This operation generates a model using points before the latest one. With |
| | 54 | | /// this method, only historical points are used to determine whether the |
| | 55 | | /// target point is an anomaly. The latest point detecting operation matches |
| | 56 | | /// the scenario of real-time monitoring of business metrics. |
| | 57 | | /// </remarks> |
| | 58 | | /// <param name='operations'> |
| | 59 | | /// The operations group for this extension method. |
| | 60 | | /// </param> |
| | 61 | | /// <param name='body'> |
| | 62 | | /// Time series points and period if needed. Advanced model parameters can also |
| | 63 | | /// be set in the request. |
| | 64 | | /// </param> |
| | 65 | | /// <param name='cancellationToken'> |
| | 66 | | /// The cancellation token. |
| | 67 | | /// </param> |
| | 68 | | public static async Task<LastDetectResponse> LastDetectAsync(this IAnomalyDetectorClient operations, Request |
| | 69 | | { |
| 0 | 70 | | using (var _result = await operations.LastDetectWithHttpMessagesAsync(body, null, cancellationToken).Con |
| | 71 | | { |
| 0 | 72 | | return _result.Body; |
| | 73 | | } |
| 0 | 74 | | } |
| | 75 | |
|
| | 76 | | } |
| | 77 | | } |