-
Notifications
You must be signed in to change notification settings - Fork 4.5k
/
TillageData.cs
895 lines (851 loc) · 66 KB
/
TillageData.cs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// <auto-generated/>
#nullable disable
using System;
using System.Collections.Generic;
using System.Threading.Tasks;
using Azure;
using Azure.Core;
using Azure.Core.Pipeline;
namespace Azure.Verticals.AgriFood.Farming
{
// Data plane generated sub-client.
/// <summary> The TillageData sub-client. </summary>
public partial class TillageData
{
private static readonly string[] AuthorizationScopes = new string[] { "https://farmbeats.azure.net/.default" };
private readonly TokenCredential _tokenCredential;
private readonly HttpPipeline _pipeline;
private readonly Uri _endpoint;
private readonly string _apiVersion;
/// <summary> The ClientDiagnostics is used to provide tracing support for the client library. </summary>
internal ClientDiagnostics ClientDiagnostics { get; }
/// <summary> The HTTP pipeline for sending and receiving REST requests and responses. </summary>
public virtual HttpPipeline Pipeline => _pipeline;
/// <summary> Initializes a new instance of TillageData for mocking. </summary>
protected TillageData()
{
}
/// <summary> Initializes a new instance of TillageData. </summary>
/// <param name="clientDiagnostics"> The handler for diagnostic messaging in the client. </param>
/// <param name="pipeline"> The HTTP pipeline for sending and receiving REST requests and responses. </param>
/// <param name="tokenCredential"> The token credential to copy. </param>
/// <param name="endpoint"> server parameter. </param>
/// <param name="apiVersion"> Api Version. </param>
internal TillageData(ClientDiagnostics clientDiagnostics, HttpPipeline pipeline, TokenCredential tokenCredential, Uri endpoint, string apiVersion)
{
ClientDiagnostics = clientDiagnostics;
_pipeline = pipeline;
_tokenCredential = tokenCredential;
_endpoint = endpoint;
_apiVersion = apiVersion;
}
/// <summary> Get a specified tillage data resource under a particular party. </summary>
/// <param name="partyId"> ID of the associated party resource. </param>
/// <param name="tillageDataId"> ID of the tillage data resource. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. Details of the response body schema are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetTillageDataAsync(String,String,RequestContext)']/*" />
public virtual async Task<Response> GetTillageDataAsync(string partyId, string tillageDataId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
Argument.AssertNotNullOrEmpty(tillageDataId, nameof(tillageDataId));
using var scope = ClientDiagnostics.CreateScope("TillageData.GetTillageData");
scope.Start();
try
{
using HttpMessage message = CreateGetTillageDataRequest(partyId, tillageDataId, context);
return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Get a specified tillage data resource under a particular party. </summary>
/// <param name="partyId"> ID of the associated party resource. </param>
/// <param name="tillageDataId"> ID of the tillage data resource. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. Details of the response body schema are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetTillageData(String,String,RequestContext)']/*" />
public virtual Response GetTillageData(string partyId, string tillageDataId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
Argument.AssertNotNullOrEmpty(tillageDataId, nameof(tillageDataId));
using var scope = ClientDiagnostics.CreateScope("TillageData.GetTillageData");
scope.Start();
try
{
using HttpMessage message = CreateGetTillageDataRequest(partyId, tillageDataId, context);
return _pipeline.ProcessMessage(message, context);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Creates or updates an tillage data resource under a particular party. </summary>
/// <param name="partyId"> ID of the associated party. </param>
/// <param name="tillageDataId"> ID of the tillage data resource. </param>
/// <param name="content"> The content to send as the body of the request. Details of the request body schema are in the Remarks section below. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/>, <paramref name="tillageDataId"/> or <paramref name="content"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. Details of the response body schema are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='CreateOrUpdateAsync(String,String,RequestContent,RequestContext)']/*" />
public virtual async Task<Response> CreateOrUpdateAsync(string partyId, string tillageDataId, RequestContent content, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
Argument.AssertNotNullOrEmpty(tillageDataId, nameof(tillageDataId));
Argument.AssertNotNull(content, nameof(content));
using var scope = ClientDiagnostics.CreateScope("TillageData.CreateOrUpdate");
scope.Start();
try
{
using HttpMessage message = CreateCreateOrUpdateRequest(partyId, tillageDataId, content, context);
return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Creates or updates an tillage data resource under a particular party. </summary>
/// <param name="partyId"> ID of the associated party. </param>
/// <param name="tillageDataId"> ID of the tillage data resource. </param>
/// <param name="content"> The content to send as the body of the request. Details of the request body schema are in the Remarks section below. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/>, <paramref name="tillageDataId"/> or <paramref name="content"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. Details of the response body schema are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='CreateOrUpdate(String,String,RequestContent,RequestContext)']/*" />
public virtual Response CreateOrUpdate(string partyId, string tillageDataId, RequestContent content, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
Argument.AssertNotNullOrEmpty(tillageDataId, nameof(tillageDataId));
Argument.AssertNotNull(content, nameof(content));
using var scope = ClientDiagnostics.CreateScope("TillageData.CreateOrUpdate");
scope.Start();
try
{
using HttpMessage message = CreateCreateOrUpdateRequest(partyId, tillageDataId, content, context);
return _pipeline.ProcessMessage(message, context);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Deletes a specified tillage data resource under a particular party. </summary>
/// <param name="partyId"> ID of the associated party resource. </param>
/// <param name="tillageDataId"> ID of the tillage data. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='DeleteAsync(String,String,RequestContext)']/*" />
public virtual async Task<Response> DeleteAsync(string partyId, string tillageDataId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
Argument.AssertNotNullOrEmpty(tillageDataId, nameof(tillageDataId));
using var scope = ClientDiagnostics.CreateScope("TillageData.Delete");
scope.Start();
try
{
using HttpMessage message = CreateDeleteRequest(partyId, tillageDataId, context);
return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Deletes a specified tillage data resource under a particular party. </summary>
/// <param name="partyId"> ID of the associated party resource. </param>
/// <param name="tillageDataId"> ID of the tillage data. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> or <paramref name="tillageDataId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='Delete(String,String,RequestContext)']/*" />
public virtual Response Delete(string partyId, string tillageDataId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
Argument.AssertNotNullOrEmpty(tillageDataId, nameof(tillageDataId));
using var scope = ClientDiagnostics.CreateScope("TillageData.Delete");
scope.Start();
try
{
using HttpMessage message = CreateDeleteRequest(partyId, tillageDataId, context);
return _pipeline.ProcessMessage(message, context);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Get cascade delete job for tillage data resource. </summary>
/// <param name="jobId"> Id of the job. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="jobId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="jobId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. Details of the response body schema are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetCascadeDeleteJobDetailsAsync(String,RequestContext)']/*" />
public virtual async Task<Response> GetCascadeDeleteJobDetailsAsync(string jobId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(jobId, nameof(jobId));
using var scope = ClientDiagnostics.CreateScope("TillageData.GetCascadeDeleteJobDetails");
scope.Start();
try
{
using HttpMessage message = CreateGetCascadeDeleteJobDetailsRequest(jobId, context);
return await _pipeline.ProcessMessageAsync(message, context).ConfigureAwait(false);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Get cascade delete job for tillage data resource. </summary>
/// <param name="jobId"> Id of the job. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="jobId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="jobId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The response returned from the service. Details of the response body schema are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetCascadeDeleteJobDetails(String,RequestContext)']/*" />
public virtual Response GetCascadeDeleteJobDetails(string jobId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(jobId, nameof(jobId));
using var scope = ClientDiagnostics.CreateScope("TillageData.GetCascadeDeleteJobDetails");
scope.Start();
try
{
using HttpMessage message = CreateGetCascadeDeleteJobDetailsRequest(jobId, context);
return _pipeline.ProcessMessage(message, context);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Returns a paginated list of tillage data resources under a particular farm. </summary>
/// <param name="partyId"> ID of the associated party. </param>
/// <param name="minTillageDepth"> Minimum measured tillage depth (inclusive). </param>
/// <param name="maxTillageDepth"> Maximum measured tillage depth (inclusive). </param>
/// <param name="minTillagePressure"> Minimum pressure applied to a tillage implement (inclusive). </param>
/// <param name="maxTillagePressure"> Maximum pressure applied to a tillage implement (inclusive). </param>
/// <param name="sources"> Sources of the operation data. </param>
/// <param name="associatedBoundaryIds"> Boundary IDs associated with operation data. </param>
/// <param name="minOperationStartDateTime"> Minimum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationStartDateTime"> Maximum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationEndDateTime"> Minimum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationEndDateTime"> Maximum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationModifiedDateTime"> Minimum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationModifiedDateTime"> Maximum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minArea"> Minimum area for which operation was applied (inclusive). </param>
/// <param name="maxArea"> Maximum area for which operation was applied (inclusive). </param>
/// <param name="ids"> Ids of the resource. </param>
/// <param name="names"> Names of the resource. </param>
/// <param name="propertyFilters">
/// Filters on key-value pairs within the Properties object.
/// eg. "{testKey} eq {testValue}".
/// </param>
/// <param name="statuses"> Statuses of the resource. </param>
/// <param name="minCreatedDateTime"> Minimum creation date of resource (inclusive). </param>
/// <param name="maxCreatedDateTime"> Maximum creation date of resource (inclusive). </param>
/// <param name="minLastModifiedDateTime"> Minimum last modified date of resource (inclusive). </param>
/// <param name="maxLastModifiedDateTime"> Maximum last modified date of resource (inclusive). </param>
/// <param name="maxPageSize">
/// Maximum number of items needed (inclusive).
/// Minimum = 10, Maximum = 1000, Default value = 50.
/// </param>
/// <param name="skipToken"> Skip token for getting next set of results. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The <see cref="AsyncPageable{T}"/> from the service containing a list of <see cref="BinaryData"/> objects. Details of the body schema for each item in the collection are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetAllTillageDataByPartyIdAsync(String,Double,Double,Double,Double,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Double,Double,IEnumerable,IEnumerable,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Int32,String,RequestContext)']/*" />
public virtual AsyncPageable<BinaryData> GetAllTillageDataByPartyIdAsync(string partyId, double? minTillageDepth = null, double? maxTillageDepth = null, double? minTillagePressure = null, double? maxTillagePressure = null, IEnumerable<string> sources = null, IEnumerable<string> associatedBoundaryIds = null, DateTimeOffset? minOperationStartDateTime = null, DateTimeOffset? maxOperationStartDateTime = null, DateTimeOffset? minOperationEndDateTime = null, DateTimeOffset? maxOperationEndDateTime = null, DateTimeOffset? minOperationModifiedDateTime = null, DateTimeOffset? maxOperationModifiedDateTime = null, double? minArea = null, double? maxArea = null, IEnumerable<string> ids = null, IEnumerable<string> names = null, IEnumerable<string> propertyFilters = null, IEnumerable<string> statuses = null, DateTimeOffset? minCreatedDateTime = null, DateTimeOffset? maxCreatedDateTime = null, DateTimeOffset? minLastModifiedDateTime = null, DateTimeOffset? maxLastModifiedDateTime = null, int? maxPageSize = null, string skipToken = null, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
HttpMessage FirstPageRequest(int? pageSizeHint) => CreateGetAllTillageDataByPartyIdRequest(partyId, minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, ids, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreateGetAllTillageDataByPartyIdNextPageRequest(nextLink, partyId, minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, ids, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
return PageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => BinaryData.FromString(e.GetRawText()), ClientDiagnostics, _pipeline, "TillageData.GetAllTillageDataByPartyId", "value", "nextLink", context);
}
/// <summary> Returns a paginated list of tillage data resources under a particular farm. </summary>
/// <param name="partyId"> ID of the associated party. </param>
/// <param name="minTillageDepth"> Minimum measured tillage depth (inclusive). </param>
/// <param name="maxTillageDepth"> Maximum measured tillage depth (inclusive). </param>
/// <param name="minTillagePressure"> Minimum pressure applied to a tillage implement (inclusive). </param>
/// <param name="maxTillagePressure"> Maximum pressure applied to a tillage implement (inclusive). </param>
/// <param name="sources"> Sources of the operation data. </param>
/// <param name="associatedBoundaryIds"> Boundary IDs associated with operation data. </param>
/// <param name="minOperationStartDateTime"> Minimum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationStartDateTime"> Maximum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationEndDateTime"> Minimum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationEndDateTime"> Maximum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationModifiedDateTime"> Minimum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationModifiedDateTime"> Maximum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minArea"> Minimum area for which operation was applied (inclusive). </param>
/// <param name="maxArea"> Maximum area for which operation was applied (inclusive). </param>
/// <param name="ids"> Ids of the resource. </param>
/// <param name="names"> Names of the resource. </param>
/// <param name="propertyFilters">
/// Filters on key-value pairs within the Properties object.
/// eg. "{testKey} eq {testValue}".
/// </param>
/// <param name="statuses"> Statuses of the resource. </param>
/// <param name="minCreatedDateTime"> Minimum creation date of resource (inclusive). </param>
/// <param name="maxCreatedDateTime"> Maximum creation date of resource (inclusive). </param>
/// <param name="minLastModifiedDateTime"> Minimum last modified date of resource (inclusive). </param>
/// <param name="maxLastModifiedDateTime"> Maximum last modified date of resource (inclusive). </param>
/// <param name="maxPageSize">
/// Maximum number of items needed (inclusive).
/// Minimum = 10, Maximum = 1000, Default value = 50.
/// </param>
/// <param name="skipToken"> Skip token for getting next set of results. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="partyId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="partyId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The <see cref="Pageable{T}"/> from the service containing a list of <see cref="BinaryData"/> objects. Details of the body schema for each item in the collection are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetAllTillageDataByPartyId(String,Double,Double,Double,Double,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Double,Double,IEnumerable,IEnumerable,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Int32,String,RequestContext)']/*" />
public virtual Pageable<BinaryData> GetAllTillageDataByPartyId(string partyId, double? minTillageDepth = null, double? maxTillageDepth = null, double? minTillagePressure = null, double? maxTillagePressure = null, IEnumerable<string> sources = null, IEnumerable<string> associatedBoundaryIds = null, DateTimeOffset? minOperationStartDateTime = null, DateTimeOffset? maxOperationStartDateTime = null, DateTimeOffset? minOperationEndDateTime = null, DateTimeOffset? maxOperationEndDateTime = null, DateTimeOffset? minOperationModifiedDateTime = null, DateTimeOffset? maxOperationModifiedDateTime = null, double? minArea = null, double? maxArea = null, IEnumerable<string> ids = null, IEnumerable<string> names = null, IEnumerable<string> propertyFilters = null, IEnumerable<string> statuses = null, DateTimeOffset? minCreatedDateTime = null, DateTimeOffset? maxCreatedDateTime = null, DateTimeOffset? minLastModifiedDateTime = null, DateTimeOffset? maxLastModifiedDateTime = null, int? maxPageSize = null, string skipToken = null, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(partyId, nameof(partyId));
HttpMessage FirstPageRequest(int? pageSizeHint) => CreateGetAllTillageDataByPartyIdRequest(partyId, minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, ids, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreateGetAllTillageDataByPartyIdNextPageRequest(nextLink, partyId, minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, ids, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
return PageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => BinaryData.FromString(e.GetRawText()), ClientDiagnostics, _pipeline, "TillageData.GetAllTillageDataByPartyId", "value", "nextLink", context);
}
/// <summary> Returns a paginated list of tillage data resources across all parties. </summary>
/// <param name="minTillageDepth"> Minimum measured tillage depth (inclusive). </param>
/// <param name="maxTillageDepth"> Maximum measured tillage depth (inclusive). </param>
/// <param name="minTillagePressure"> Minimum pressure applied to a tillage implement (inclusive). </param>
/// <param name="maxTillagePressure"> Maximum pressure applied to a tillage implement (inclusive). </param>
/// <param name="sources"> Sources of the operation data. </param>
/// <param name="associatedBoundaryIds"> Boundary IDs associated with operation data. </param>
/// <param name="minOperationStartDateTime"> Minimum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationStartDateTime"> Maximum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationEndDateTime"> Minimum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationEndDateTime"> Maximum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationModifiedDateTime"> Minimum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationModifiedDateTime"> Maximum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minArea"> Minimum area for which operation was applied (inclusive). </param>
/// <param name="maxArea"> Maximum area for which operation was applied (inclusive). </param>
/// <param name="tillageDataIds"> Ids of the resource. </param>
/// <param name="names"> Names of the resource. </param>
/// <param name="propertyFilters">
/// Filters on key-value pairs within the Properties object.
/// eg. "{testKey} eq {testValue}".
/// </param>
/// <param name="statuses"> Statuses of the resource. </param>
/// <param name="minCreatedDateTime"> Minimum creation date of resource (inclusive). </param>
/// <param name="maxCreatedDateTime"> Maximum creation date of resource (inclusive). </param>
/// <param name="minLastModifiedDateTime"> Minimum last modified date of resource (inclusive). </param>
/// <param name="maxLastModifiedDateTime"> Maximum last modified date of resource (inclusive). </param>
/// <param name="maxPageSize">
/// Maximum number of items needed (inclusive).
/// Minimum = 10, Maximum = 1000, Default value = 50.
/// </param>
/// <param name="skipToken"> Skip token for getting next set of results. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The <see cref="AsyncPageable{T}"/> from the service containing a list of <see cref="BinaryData"/> objects. Details of the body schema for each item in the collection are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetAllTillageDataAsync(Double,Double,Double,Double,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Double,Double,IEnumerable,IEnumerable,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Int32,String,RequestContext)']/*" />
public virtual AsyncPageable<BinaryData> GetAllTillageDataAsync(double? minTillageDepth = null, double? maxTillageDepth = null, double? minTillagePressure = null, double? maxTillagePressure = null, IEnumerable<string> sources = null, IEnumerable<string> associatedBoundaryIds = null, DateTimeOffset? minOperationStartDateTime = null, DateTimeOffset? maxOperationStartDateTime = null, DateTimeOffset? minOperationEndDateTime = null, DateTimeOffset? maxOperationEndDateTime = null, DateTimeOffset? minOperationModifiedDateTime = null, DateTimeOffset? maxOperationModifiedDateTime = null, double? minArea = null, double? maxArea = null, IEnumerable<string> tillageDataIds = null, IEnumerable<string> names = null, IEnumerable<string> propertyFilters = null, IEnumerable<string> statuses = null, DateTimeOffset? minCreatedDateTime = null, DateTimeOffset? maxCreatedDateTime = null, DateTimeOffset? minLastModifiedDateTime = null, DateTimeOffset? maxLastModifiedDateTime = null, int? maxPageSize = null, string skipToken = null, RequestContext context = null)
{
HttpMessage FirstPageRequest(int? pageSizeHint) => CreateGetAllTillageDataRequest(minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, tillageDataIds, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreateGetAllTillageDataNextPageRequest(nextLink, minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, tillageDataIds, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
return PageableHelpers.CreateAsyncPageable(FirstPageRequest, NextPageRequest, e => BinaryData.FromString(e.GetRawText()), ClientDiagnostics, _pipeline, "TillageData.GetAllTillageData", "value", "nextLink", context);
}
/// <summary> Returns a paginated list of tillage data resources across all parties. </summary>
/// <param name="minTillageDepth"> Minimum measured tillage depth (inclusive). </param>
/// <param name="maxTillageDepth"> Maximum measured tillage depth (inclusive). </param>
/// <param name="minTillagePressure"> Minimum pressure applied to a tillage implement (inclusive). </param>
/// <param name="maxTillagePressure"> Maximum pressure applied to a tillage implement (inclusive). </param>
/// <param name="sources"> Sources of the operation data. </param>
/// <param name="associatedBoundaryIds"> Boundary IDs associated with operation data. </param>
/// <param name="minOperationStartDateTime"> Minimum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationStartDateTime"> Maximum start date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationEndDateTime"> Minimum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationEndDateTime"> Maximum end date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minOperationModifiedDateTime"> Minimum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="maxOperationModifiedDateTime"> Maximum modified date-time of the operation data, sample format: yyyy-MM-ddTHH:mm:ssZ (inclusive). </param>
/// <param name="minArea"> Minimum area for which operation was applied (inclusive). </param>
/// <param name="maxArea"> Maximum area for which operation was applied (inclusive). </param>
/// <param name="tillageDataIds"> Ids of the resource. </param>
/// <param name="names"> Names of the resource. </param>
/// <param name="propertyFilters">
/// Filters on key-value pairs within the Properties object.
/// eg. "{testKey} eq {testValue}".
/// </param>
/// <param name="statuses"> Statuses of the resource. </param>
/// <param name="minCreatedDateTime"> Minimum creation date of resource (inclusive). </param>
/// <param name="maxCreatedDateTime"> Maximum creation date of resource (inclusive). </param>
/// <param name="minLastModifiedDateTime"> Minimum last modified date of resource (inclusive). </param>
/// <param name="maxLastModifiedDateTime"> Maximum last modified date of resource (inclusive). </param>
/// <param name="maxPageSize">
/// Maximum number of items needed (inclusive).
/// Minimum = 10, Maximum = 1000, Default value = 50.
/// </param>
/// <param name="skipToken"> Skip token for getting next set of results. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The <see cref="Pageable{T}"/> from the service containing a list of <see cref="BinaryData"/> objects. Details of the body schema for each item in the collection are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='GetAllTillageData(Double,Double,Double,Double,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Double,Double,IEnumerable,IEnumerable,IEnumerable,IEnumerable,DateTimeOffset,DateTimeOffset,DateTimeOffset,DateTimeOffset,Int32,String,RequestContext)']/*" />
public virtual Pageable<BinaryData> GetAllTillageData(double? minTillageDepth = null, double? maxTillageDepth = null, double? minTillagePressure = null, double? maxTillagePressure = null, IEnumerable<string> sources = null, IEnumerable<string> associatedBoundaryIds = null, DateTimeOffset? minOperationStartDateTime = null, DateTimeOffset? maxOperationStartDateTime = null, DateTimeOffset? minOperationEndDateTime = null, DateTimeOffset? maxOperationEndDateTime = null, DateTimeOffset? minOperationModifiedDateTime = null, DateTimeOffset? maxOperationModifiedDateTime = null, double? minArea = null, double? maxArea = null, IEnumerable<string> tillageDataIds = null, IEnumerable<string> names = null, IEnumerable<string> propertyFilters = null, IEnumerable<string> statuses = null, DateTimeOffset? minCreatedDateTime = null, DateTimeOffset? maxCreatedDateTime = null, DateTimeOffset? minLastModifiedDateTime = null, DateTimeOffset? maxLastModifiedDateTime = null, int? maxPageSize = null, string skipToken = null, RequestContext context = null)
{
HttpMessage FirstPageRequest(int? pageSizeHint) => CreateGetAllTillageDataRequest(minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, tillageDataIds, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
HttpMessage NextPageRequest(int? pageSizeHint, string nextLink) => CreateGetAllTillageDataNextPageRequest(nextLink, minTillageDepth, maxTillageDepth, minTillagePressure, maxTillagePressure, sources, associatedBoundaryIds, minOperationStartDateTime, maxOperationStartDateTime, minOperationEndDateTime, maxOperationEndDateTime, minOperationModifiedDateTime, maxOperationModifiedDateTime, minArea, maxArea, tillageDataIds, names, propertyFilters, statuses, minCreatedDateTime, maxCreatedDateTime, minLastModifiedDateTime, maxLastModifiedDateTime, maxPageSize, skipToken, context);
return PageableHelpers.CreatePageable(FirstPageRequest, NextPageRequest, e => BinaryData.FromString(e.GetRawText()), ClientDiagnostics, _pipeline, "TillageData.GetAllTillageData", "value", "nextLink", context);
}
/// <summary> Create cascade delete job for tillage data resource. </summary>
/// <param name="waitUntil"> <see cref="WaitUntil.Completed"/> if the method should wait to return until the long-running operation has completed on the service; <see cref="WaitUntil.Started"/> if it should return after starting the operation. For more information on long-running operations, please see <see href="https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/samples/LongRunningOperations.md"> Azure.Core Long-Running Operation samples</see>. </param>
/// <param name="jobId"> Job Id supplied by end user. </param>
/// <param name="partyId"> Id of the party. </param>
/// <param name="tillageDataId"> Id of the tillage data. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="jobId"/>, <paramref name="partyId"/> or <paramref name="tillageDataId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="jobId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The <see cref="Operation{T}"/> from the service that will contain a <see cref="BinaryData"/> object once the asynchronous operation on the service has completed. Details of the body schema for the operation's final value are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='CreateCascadeDeleteJobAsync(WaitUntil,String,String,String,RequestContext)']/*" />
public virtual async Task<Operation<BinaryData>> CreateCascadeDeleteJobAsync(WaitUntil waitUntil, string jobId, string partyId, string tillageDataId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(jobId, nameof(jobId));
Argument.AssertNotNull(partyId, nameof(partyId));
Argument.AssertNotNull(tillageDataId, nameof(tillageDataId));
using var scope = ClientDiagnostics.CreateScope("TillageData.CreateCascadeDeleteJob");
scope.Start();
try
{
using HttpMessage message = CreateCreateCascadeDeleteJobRequest(jobId, partyId, tillageDataId, context);
return await ProtocolOperationHelpers.ProcessMessageAsync(_pipeline, message, ClientDiagnostics, "TillageData.CreateCascadeDeleteJob", OperationFinalStateVia.Location, context, waitUntil).ConfigureAwait(false);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
/// <summary> Create cascade delete job for tillage data resource. </summary>
/// <param name="waitUntil"> <see cref="WaitUntil.Completed"/> if the method should wait to return until the long-running operation has completed on the service; <see cref="WaitUntil.Started"/> if it should return after starting the operation. For more information on long-running operations, please see <see href="https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/core/Azure.Core/samples/LongRunningOperations.md"> Azure.Core Long-Running Operation samples</see>. </param>
/// <param name="jobId"> Job Id supplied by end user. </param>
/// <param name="partyId"> Id of the party. </param>
/// <param name="tillageDataId"> Id of the tillage data. </param>
/// <param name="context"> The request context, which can override default behaviors of the client pipeline on a per-call basis. </param>
/// <exception cref="ArgumentNullException"> <paramref name="jobId"/>, <paramref name="partyId"/> or <paramref name="tillageDataId"/> is null. </exception>
/// <exception cref="ArgumentException"> <paramref name="jobId"/> is an empty string, and was expected to be non-empty. </exception>
/// <exception cref="RequestFailedException"> Service returned a non-success status code. </exception>
/// <returns> The <see cref="Operation{T}"/> from the service that will contain a <see cref="BinaryData"/> object once the asynchronous operation on the service has completed. Details of the body schema for the operation's final value are in the Remarks section below. </returns>
/// <include file="Docs/TillageData.xml" path="doc/members/member[@name='CreateCascadeDeleteJob(WaitUntil,String,String,String,RequestContext)']/*" />
public virtual Operation<BinaryData> CreateCascadeDeleteJob(WaitUntil waitUntil, string jobId, string partyId, string tillageDataId, RequestContext context = null)
{
Argument.AssertNotNullOrEmpty(jobId, nameof(jobId));
Argument.AssertNotNull(partyId, nameof(partyId));
Argument.AssertNotNull(tillageDataId, nameof(tillageDataId));
using var scope = ClientDiagnostics.CreateScope("TillageData.CreateCascadeDeleteJob");
scope.Start();
try
{
using HttpMessage message = CreateCreateCascadeDeleteJobRequest(jobId, partyId, tillageDataId, context);
return ProtocolOperationHelpers.ProcessMessage(_pipeline, message, ClientDiagnostics, "TillageData.CreateCascadeDeleteJob", OperationFinalStateVia.Location, context, waitUntil);
}
catch (Exception e)
{
scope.Failed(e);
throw;
}
}
internal HttpMessage CreateGetAllTillageDataByPartyIdRequest(string partyId, double? minTillageDepth, double? maxTillageDepth, double? minTillagePressure, double? maxTillagePressure, IEnumerable<string> sources, IEnumerable<string> associatedBoundaryIds, DateTimeOffset? minOperationStartDateTime, DateTimeOffset? maxOperationStartDateTime, DateTimeOffset? minOperationEndDateTime, DateTimeOffset? maxOperationEndDateTime, DateTimeOffset? minOperationModifiedDateTime, DateTimeOffset? maxOperationModifiedDateTime, double? minArea, double? maxArea, IEnumerable<string> ids, IEnumerable<string> names, IEnumerable<string> propertyFilters, IEnumerable<string> statuses, DateTimeOffset? minCreatedDateTime, DateTimeOffset? maxCreatedDateTime, DateTimeOffset? minLastModifiedDateTime, DateTimeOffset? maxLastModifiedDateTime, int? maxPageSize, string skipToken, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier200);
var request = message.Request;
request.Method = RequestMethod.Get;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendPath("/parties/", false);
uri.AppendPath(partyId, true);
uri.AppendPath("/tillage-data", false);
if (minTillageDepth != null)
{
uri.AppendQuery("minTillageDepth", minTillageDepth.Value, true);
}
if (maxTillageDepth != null)
{
uri.AppendQuery("maxTillageDepth", maxTillageDepth.Value, true);
}
if (minTillagePressure != null)
{
uri.AppendQuery("minTillagePressure", minTillagePressure.Value, true);
}
if (maxTillagePressure != null)
{
uri.AppendQuery("maxTillagePressure", maxTillagePressure.Value, true);
}
if (sources != null)
{
foreach (var param in sources)
{
uri.AppendQuery("sources", param, true);
}
}
if (associatedBoundaryIds != null)
{
foreach (var param in associatedBoundaryIds)
{
uri.AppendQuery("associatedBoundaryIds", param, true);
}
}
if (minOperationStartDateTime != null)
{
uri.AppendQuery("minOperationStartDateTime", minOperationStartDateTime.Value, "O", true);
}
if (maxOperationStartDateTime != null)
{
uri.AppendQuery("maxOperationStartDateTime", maxOperationStartDateTime.Value, "O", true);
}
if (minOperationEndDateTime != null)
{
uri.AppendQuery("minOperationEndDateTime", minOperationEndDateTime.Value, "O", true);
}
if (maxOperationEndDateTime != null)
{
uri.AppendQuery("maxOperationEndDateTime", maxOperationEndDateTime.Value, "O", true);
}
if (minOperationModifiedDateTime != null)
{
uri.AppendQuery("minOperationModifiedDateTime", minOperationModifiedDateTime.Value, "O", true);
}
if (maxOperationModifiedDateTime != null)
{
uri.AppendQuery("maxOperationModifiedDateTime", maxOperationModifiedDateTime.Value, "O", true);
}
if (minArea != null)
{
uri.AppendQuery("minArea", minArea.Value, true);
}
if (maxArea != null)
{
uri.AppendQuery("maxArea", maxArea.Value, true);
}
if (ids != null)
{
foreach (var param in ids)
{
uri.AppendQuery("ids", param, true);
}
}
if (names != null)
{
foreach (var param in names)
{
uri.AppendQuery("names", param, true);
}
}
if (propertyFilters != null)
{
foreach (var param in propertyFilters)
{
uri.AppendQuery("propertyFilters", param, true);
}
}
if (statuses != null)
{
foreach (var param in statuses)
{
uri.AppendQuery("statuses", param, true);
}
}
if (minCreatedDateTime != null)
{
uri.AppendQuery("minCreatedDateTime", minCreatedDateTime.Value, "O", true);
}
if (maxCreatedDateTime != null)
{
uri.AppendQuery("maxCreatedDateTime", maxCreatedDateTime.Value, "O", true);
}
if (minLastModifiedDateTime != null)
{
uri.AppendQuery("minLastModifiedDateTime", minLastModifiedDateTime.Value, "O", true);
}
if (maxLastModifiedDateTime != null)
{
uri.AppendQuery("maxLastModifiedDateTime", maxLastModifiedDateTime.Value, "O", true);
}
if (maxPageSize != null)
{
uri.AppendQuery("maxPageSize", maxPageSize.Value, true);
}
if (skipToken != null)
{
uri.AppendQuery("skipToken", skipToken, true);
}
uri.AppendQuery("api-version", _apiVersion, true);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
internal HttpMessage CreateGetTillageDataRequest(string partyId, string tillageDataId, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier200);
var request = message.Request;
request.Method = RequestMethod.Get;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendPath("/parties/", false);
uri.AppendPath(partyId, true);
uri.AppendPath("/tillage-data/", false);
uri.AppendPath(tillageDataId, true);
uri.AppendQuery("api-version", _apiVersion, true);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
internal HttpMessage CreateCreateOrUpdateRequest(string partyId, string tillageDataId, RequestContent content, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier200201);
var request = message.Request;
request.Method = RequestMethod.Patch;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendPath("/parties/", false);
uri.AppendPath(partyId, true);
uri.AppendPath("/tillage-data/", false);
uri.AppendPath(tillageDataId, true);
uri.AppendQuery("api-version", _apiVersion, true);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
request.Headers.Add("Content-Type", "application/merge-patch+json");
request.Content = content;
return message;
}
internal HttpMessage CreateDeleteRequest(string partyId, string tillageDataId, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier204);
var request = message.Request;
request.Method = RequestMethod.Delete;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendPath("/parties/", false);
uri.AppendPath(partyId, true);
uri.AppendPath("/tillage-data/", false);
uri.AppendPath(tillageDataId, true);
uri.AppendQuery("api-version", _apiVersion, true);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
internal HttpMessage CreateGetAllTillageDataRequest(double? minTillageDepth, double? maxTillageDepth, double? minTillagePressure, double? maxTillagePressure, IEnumerable<string> sources, IEnumerable<string> associatedBoundaryIds, DateTimeOffset? minOperationStartDateTime, DateTimeOffset? maxOperationStartDateTime, DateTimeOffset? minOperationEndDateTime, DateTimeOffset? maxOperationEndDateTime, DateTimeOffset? minOperationModifiedDateTime, DateTimeOffset? maxOperationModifiedDateTime, double? minArea, double? maxArea, IEnumerable<string> tillageDataIds, IEnumerable<string> names, IEnumerable<string> propertyFilters, IEnumerable<string> statuses, DateTimeOffset? minCreatedDateTime, DateTimeOffset? maxCreatedDateTime, DateTimeOffset? minLastModifiedDateTime, DateTimeOffset? maxLastModifiedDateTime, int? maxPageSize, string skipToken, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier200);
var request = message.Request;
request.Method = RequestMethod.Get;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendPath("/tillage-data", false);
if (minTillageDepth != null)
{
uri.AppendQuery("minTillageDepth", minTillageDepth.Value, true);
}
if (maxTillageDepth != null)
{
uri.AppendQuery("maxTillageDepth", maxTillageDepth.Value, true);
}
if (minTillagePressure != null)
{
uri.AppendQuery("minTillagePressure", minTillagePressure.Value, true);
}
if (maxTillagePressure != null)
{
uri.AppendQuery("maxTillagePressure", maxTillagePressure.Value, true);
}
if (sources != null)
{
foreach (var param in sources)
{
uri.AppendQuery("sources", param, true);
}
}
if (associatedBoundaryIds != null)
{
foreach (var param in associatedBoundaryIds)
{
uri.AppendQuery("associatedBoundaryIds", param, true);
}
}
if (minOperationStartDateTime != null)
{
uri.AppendQuery("minOperationStartDateTime", minOperationStartDateTime.Value, "O", true);
}
if (maxOperationStartDateTime != null)
{
uri.AppendQuery("maxOperationStartDateTime", maxOperationStartDateTime.Value, "O", true);
}
if (minOperationEndDateTime != null)
{
uri.AppendQuery("minOperationEndDateTime", minOperationEndDateTime.Value, "O", true);
}
if (maxOperationEndDateTime != null)
{
uri.AppendQuery("maxOperationEndDateTime", maxOperationEndDateTime.Value, "O", true);
}
if (minOperationModifiedDateTime != null)
{
uri.AppendQuery("minOperationModifiedDateTime", minOperationModifiedDateTime.Value, "O", true);
}
if (maxOperationModifiedDateTime != null)
{
uri.AppendQuery("maxOperationModifiedDateTime", maxOperationModifiedDateTime.Value, "O", true);
}
if (minArea != null)
{
uri.AppendQuery("minArea", minArea.Value, true);
}
if (maxArea != null)
{
uri.AppendQuery("maxArea", maxArea.Value, true);
}
if (tillageDataIds != null)
{
foreach (var param in tillageDataIds)
{
uri.AppendQuery("ids", param, true);
}
}
if (names != null)
{
foreach (var param in names)
{
uri.AppendQuery("names", param, true);
}
}
if (propertyFilters != null)
{
foreach (var param in propertyFilters)
{
uri.AppendQuery("propertyFilters", param, true);
}
}
if (statuses != null)
{
foreach (var param in statuses)
{
uri.AppendQuery("statuses", param, true);
}
}
if (minCreatedDateTime != null)
{
uri.AppendQuery("minCreatedDateTime", minCreatedDateTime.Value, "O", true);
}
if (maxCreatedDateTime != null)
{
uri.AppendQuery("maxCreatedDateTime", maxCreatedDateTime.Value, "O", true);
}
if (minLastModifiedDateTime != null)
{
uri.AppendQuery("minLastModifiedDateTime", minLastModifiedDateTime.Value, "O", true);
}
if (maxLastModifiedDateTime != null)
{
uri.AppendQuery("maxLastModifiedDateTime", maxLastModifiedDateTime.Value, "O", true);
}
if (maxPageSize != null)
{
uri.AppendQuery("maxPageSize", maxPageSize.Value, true);
}
if (skipToken != null)
{
uri.AppendQuery("skipToken", skipToken, true);
}
uri.AppendQuery("api-version", _apiVersion, true);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
internal HttpMessage CreateCreateCascadeDeleteJobRequest(string jobId, string partyId, string tillageDataId, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier202);
var request = message.Request;
request.Method = RequestMethod.Put;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendPath("/tillage-data/cascade-delete/", false);
uri.AppendPath(jobId, true);
uri.AppendQuery("partyId", partyId, true);
uri.AppendQuery("tillageDataId", tillageDataId, true);
uri.AppendQuery("api-version", _apiVersion, true);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
internal HttpMessage CreateGetCascadeDeleteJobDetailsRequest(string jobId, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier200);
var request = message.Request;
request.Method = RequestMethod.Get;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendPath("/tillage-data/cascade-delete/", false);
uri.AppendPath(jobId, true);
uri.AppendQuery("api-version", _apiVersion, true);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
internal HttpMessage CreateGetAllTillageDataByPartyIdNextPageRequest(string nextLink, string partyId, double? minTillageDepth, double? maxTillageDepth, double? minTillagePressure, double? maxTillagePressure, IEnumerable<string> sources, IEnumerable<string> associatedBoundaryIds, DateTimeOffset? minOperationStartDateTime, DateTimeOffset? maxOperationStartDateTime, DateTimeOffset? minOperationEndDateTime, DateTimeOffset? maxOperationEndDateTime, DateTimeOffset? minOperationModifiedDateTime, DateTimeOffset? maxOperationModifiedDateTime, double? minArea, double? maxArea, IEnumerable<string> ids, IEnumerable<string> names, IEnumerable<string> propertyFilters, IEnumerable<string> statuses, DateTimeOffset? minCreatedDateTime, DateTimeOffset? maxCreatedDateTime, DateTimeOffset? minLastModifiedDateTime, DateTimeOffset? maxLastModifiedDateTime, int? maxPageSize, string skipToken, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier200);
var request = message.Request;
request.Method = RequestMethod.Get;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendRawNextLink(nextLink, false);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
internal HttpMessage CreateGetAllTillageDataNextPageRequest(string nextLink, double? minTillageDepth, double? maxTillageDepth, double? minTillagePressure, double? maxTillagePressure, IEnumerable<string> sources, IEnumerable<string> associatedBoundaryIds, DateTimeOffset? minOperationStartDateTime, DateTimeOffset? maxOperationStartDateTime, DateTimeOffset? minOperationEndDateTime, DateTimeOffset? maxOperationEndDateTime, DateTimeOffset? minOperationModifiedDateTime, DateTimeOffset? maxOperationModifiedDateTime, double? minArea, double? maxArea, IEnumerable<string> tillageDataIds, IEnumerable<string> names, IEnumerable<string> propertyFilters, IEnumerable<string> statuses, DateTimeOffset? minCreatedDateTime, DateTimeOffset? maxCreatedDateTime, DateTimeOffset? minLastModifiedDateTime, DateTimeOffset? maxLastModifiedDateTime, int? maxPageSize, string skipToken, RequestContext context)
{
var message = _pipeline.CreateMessage(context, ResponseClassifier200);
var request = message.Request;
request.Method = RequestMethod.Get;
var uri = new RawRequestUriBuilder();
uri.Reset(_endpoint);
uri.AppendRawNextLink(nextLink, false);
request.Uri = uri;
request.Headers.Add("Accept", "application/json");
return message;
}
private static ResponseClassifier _responseClassifier200;
private static ResponseClassifier ResponseClassifier200 => _responseClassifier200 ??= new StatusCodeClassifier(stackalloc ushort[] { 200 });
private static ResponseClassifier _responseClassifier200201;
private static ResponseClassifier ResponseClassifier200201 => _responseClassifier200201 ??= new StatusCodeClassifier(stackalloc ushort[] { 200, 201 });
private static ResponseClassifier _responseClassifier204;
private static ResponseClassifier ResponseClassifier204 => _responseClassifier204 ??= new StatusCodeClassifier(stackalloc ushort[] { 204 });
private static ResponseClassifier _responseClassifier202;
private static ResponseClassifier ResponseClassifier202 => _responseClassifier202 ??= new StatusCodeClassifier(stackalloc ushort[] { 202 });
}
}