-
Notifications
You must be signed in to change notification settings - Fork 4.5k
/
ArmSqlModelFactory.cs
6125 lines (5812 loc) · 426 KB
/
ArmSqlModelFactory.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
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// <auto-generated/>
#nullable disable
using System;
using System.Collections.Generic;
using System.Linq;
using System.Net;
using Azure.Core;
using Azure.ResourceManager.Models;
namespace Azure.ResourceManager.Sql.Models
{
/// <summary> Model factory for models. </summary>
public static partial class ArmSqlModelFactory
{
/// <summary> Initializes a new instance of <see cref="Sql.DataMaskingPolicyData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="location"> The location of the data masking policy. </param>
/// <param name="kind"> The kind of data masking policy. Metadata, used for Azure portal. </param>
/// <param name="dataMaskingState"> The state of the data masking policy. </param>
/// <param name="exemptPrincipals"> The list of the exempt principals. Specifies the semicolon-separated list of database users for which the data masking policy does not apply. The specified users receive data results without masking for all of the database queries. </param>
/// <param name="applicationPrincipals"> The list of the application principals. This is a legacy parameter and is no longer used. </param>
/// <param name="maskingLevel"> The masking level. This is a legacy parameter and is no longer used. </param>
/// <returns> A new <see cref="Sql.DataMaskingPolicyData"/> instance for mocking. </returns>
public static DataMaskingPolicyData DataMaskingPolicyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, AzureLocation? location = null, string kind = null, DataMaskingState? dataMaskingState = null, string exemptPrincipals = null, string applicationPrincipals = null, string maskingLevel = null)
{
return new DataMaskingPolicyData(
id,
name,
resourceType,
systemData,
location,
kind,
dataMaskingState,
exemptPrincipals,
applicationPrincipals,
maskingLevel,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.DataMaskingRule"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="location"> The location of the data masking rule. </param>
/// <param name="kind"> The kind of Data Masking Rule. Metadata, used for Azure portal. </param>
/// <param name="aliasName"> The alias name. This is a legacy parameter and is no longer used. </param>
/// <param name="ruleState"> The rule state. Used to delete a rule. To delete an existing rule, specify the schemaName, tableName, columnName, maskingFunction, and specify ruleState as disabled. However, if the rule doesn't already exist, the rule will be created with ruleState set to enabled, regardless of the provided value of ruleState. </param>
/// <param name="schemaName"> The schema name on which the data masking rule is applied. </param>
/// <param name="tableName"> The table name on which the data masking rule is applied. </param>
/// <param name="columnName"> The column name on which the data masking rule is applied. </param>
/// <param name="maskingFunction"> The masking function that is used for the data masking rule. </param>
/// <param name="numberFrom"> The numberFrom property of the masking rule. Required if maskingFunction is set to Number, otherwise this parameter will be ignored. </param>
/// <param name="numberTo"> The numberTo property of the data masking rule. Required if maskingFunction is set to Number, otherwise this parameter will be ignored. </param>
/// <param name="prefixSize"> If maskingFunction is set to Text, the number of characters to show unmasked in the beginning of the string. Otherwise, this parameter will be ignored. </param>
/// <param name="suffixSize"> If maskingFunction is set to Text, the number of characters to show unmasked at the end of the string. Otherwise, this parameter will be ignored. </param>
/// <param name="replacementString"> If maskingFunction is set to Text, the character to use for masking the unexposed part of the string. Otherwise, this parameter will be ignored. </param>
/// <returns> A new <see cref="Models.DataMaskingRule"/> instance for mocking. </returns>
public static DataMaskingRule DataMaskingRule(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, AzureLocation? location = null, string kind = null, string aliasName = null, DataMaskingRuleState? ruleState = null, string schemaName = null, string tableName = null, string columnName = null, DataMaskingFunction? maskingFunction = null, string numberFrom = null, string numberTo = null, string prefixSize = null, string suffixSize = null, string replacementString = null)
{
return new DataMaskingRule(
id,
name,
resourceType,
systemData,
location,
kind,
aliasName,
ruleState,
schemaName,
tableName,
columnName,
maskingFunction,
numberFrom,
numberTo,
prefixSize,
suffixSize,
replacementString,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.GeoBackupPolicyData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="kind"> Kind of geo backup policy. This is metadata used for the Azure portal experience. </param>
/// <param name="location"> Backup policy location. </param>
/// <param name="state"> The state of the geo backup policy. </param>
/// <param name="storageType"> The storage type of the geo backup policy. </param>
/// <returns> A new <see cref="Sql.GeoBackupPolicyData"/> instance for mocking. </returns>
public static GeoBackupPolicyData GeoBackupPolicyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string kind = null, AzureLocation? location = null, GeoBackupPolicyState state = default, string storageType = null)
{
return new GeoBackupPolicyData(
id,
name,
resourceType,
systemData,
kind,
location,
state,
storageType,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.SqlMetric"/>. </summary>
/// <param name="startOn"> The start time for the metric (ISO-8601 format). </param>
/// <param name="endOn"> The end time for the metric (ISO-8601 format). </param>
/// <param name="timeGrain"> The time step to be used to summarize the metric values. </param>
/// <param name="unit"> The unit of the metric. </param>
/// <param name="name"> The name information for the metric. </param>
/// <param name="metricValues"> The metric values for the specified time window and timestep. </param>
/// <returns> A new <see cref="Models.SqlMetric"/> instance for mocking. </returns>
public static SqlMetric SqlMetric(DateTimeOffset? startOn = null, DateTimeOffset? endOn = null, string timeGrain = null, SqlMetricUnitType? unit = null, SqlMetricName name = null, IEnumerable<SqlMetricValue> metricValues = null)
{
metricValues ??= new List<SqlMetricValue>();
return new SqlMetric(
startOn,
endOn,
timeGrain,
unit,
name,
metricValues?.ToList(),
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.SqlMetricName"/>. </summary>
/// <param name="value"> The name of the database metric. </param>
/// <param name="localizedValue"> The friendly name of the database metric. </param>
/// <returns> A new <see cref="Models.SqlMetricName"/> instance for mocking. </returns>
public static SqlMetricName SqlMetricName(string value = null, string localizedValue = null)
{
return new SqlMetricName(value, localizedValue, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.SqlMetricValue"/>. </summary>
/// <param name="count"> The number of values for the metric. </param>
/// <param name="average"> The average value of the metric. </param>
/// <param name="maximum"> The max value of the metric. </param>
/// <param name="minimum"> The min value of the metric. </param>
/// <param name="timestamp"> The metric timestamp (ISO-8601 format). </param>
/// <param name="total"> The total value of the metric. </param>
/// <returns> A new <see cref="Models.SqlMetricValue"/> instance for mocking. </returns>
public static SqlMetricValue SqlMetricValue(int? count = null, double? average = null, double? maximum = null, double? minimum = null, DateTimeOffset? timestamp = null, double? total = null)
{
return new SqlMetricValue(
count,
average,
maximum,
minimum,
timestamp,
total,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.SqlMetricDefinition"/>. </summary>
/// <param name="name"> The name information for the metric. </param>
/// <param name="primaryAggregationType"> The primary aggregation type defining how metric values are displayed. </param>
/// <param name="resourceUriString"> The resource uri of the database. </param>
/// <param name="unit"> The unit of the metric. </param>
/// <param name="metricAvailabilities"> The list of database metric availabilities for the metric. </param>
/// <returns> A new <see cref="Models.SqlMetricDefinition"/> instance for mocking. </returns>
public static SqlMetricDefinition SqlMetricDefinition(SqlMetricName name = null, SqlMetricPrimaryAggregationType? primaryAggregationType = null, string resourceUriString = null, SqlMetricDefinitionUnitType? unit = null, IEnumerable<SqlMetricAvailability> metricAvailabilities = null)
{
metricAvailabilities ??= new List<SqlMetricAvailability>();
return new SqlMetricDefinition(
name,
primaryAggregationType,
resourceUriString,
unit,
metricAvailabilities?.ToList(),
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.SqlMetricAvailability"/>. </summary>
/// <param name="retention"> The length of retention for the database metric. </param>
/// <param name="timeGrain"> The granularity of the database metric. </param>
/// <returns> A new <see cref="Models.SqlMetricAvailability"/> instance for mocking. </returns>
public static SqlMetricAvailability SqlMetricAvailability(string retention = null, string timeGrain = null)
{
return new SqlMetricAvailability(retention, timeGrain, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlServerCommunicationLinkData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="location"> Communication link location. </param>
/// <param name="kind"> Communication link kind. This property is used for Azure Portal metadata. </param>
/// <param name="state"> The state. </param>
/// <param name="partnerServer"> The name of the partner server. </param>
/// <returns> A new <see cref="Sql.SqlServerCommunicationLinkData"/> instance for mocking. </returns>
public static SqlServerCommunicationLinkData SqlServerCommunicationLinkData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, AzureLocation? location = null, string kind = null, string state = null, string partnerServer = null)
{
return new SqlServerCommunicationLinkData(
id,
name,
resourceType,
systemData,
location,
kind,
state,
partnerServer,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.ServiceObjectiveData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="serviceObjectiveName"> The name for the service objective. </param>
/// <param name="isDefault"> Gets whether the service level objective is the default service objective. </param>
/// <param name="isSystem"> Gets whether the service level objective is a system service objective. </param>
/// <param name="description"> The description for the service level objective. </param>
/// <param name="isEnabled"> Gets whether the service level objective is enabled. </param>
/// <returns> A new <see cref="Sql.ServiceObjectiveData"/> instance for mocking. </returns>
public static ServiceObjectiveData ServiceObjectiveData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string serviceObjectiveName = null, bool? isDefault = null, bool? isSystem = null, string description = null, bool? isEnabled = null)
{
return new ServiceObjectiveData(
id,
name,
resourceType,
systemData,
serviceObjectiveName,
isDefault,
isSystem,
description,
isEnabled,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.ElasticPoolActivity"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="location"> The geo-location where the resource lives. </param>
/// <param name="endOn"> The time the operation finished (ISO8601 format). </param>
/// <param name="errorCode"> The error code if available. </param>
/// <param name="errorMessage"> The error message if available. </param>
/// <param name="errorSeverity"> The error severity if available. </param>
/// <param name="operation"> The operation name. </param>
/// <param name="operationId"> The unique operation ID. </param>
/// <param name="percentComplete"> The percentage complete if available. </param>
/// <param name="requestedDatabaseDtuMax"> The requested max DTU per database if available. </param>
/// <param name="requestedDatabaseDtuMin"> The requested min DTU per database if available. </param>
/// <param name="requestedDtu"> The requested DTU for the pool if available. </param>
/// <param name="requestedElasticPoolName"> The requested name for the elastic pool if available. </param>
/// <param name="requestedStorageLimitInGB"> The requested storage limit for the pool in GB if available. </param>
/// <param name="elasticPoolName"> The name of the elastic pool. </param>
/// <param name="serverName"> The name of the server the elastic pool is in. </param>
/// <param name="startOn"> The time the operation started (ISO8601 format). </param>
/// <param name="state"> The current state of the operation. </param>
/// <param name="requestedStorageLimitInMB"> The requested storage limit in MB. </param>
/// <param name="requestedDatabaseDtuGuarantee"> The requested per database DTU guarantee. </param>
/// <param name="requestedDatabaseDtuCap"> The requested per database DTU cap. </param>
/// <param name="requestedDtuGuarantee"> The requested DTU guarantee. </param>
/// <returns> A new <see cref="Models.ElasticPoolActivity"/> instance for mocking. </returns>
public static ElasticPoolActivity ElasticPoolActivity(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, AzureLocation? location = null, DateTimeOffset? endOn = null, int? errorCode = null, string errorMessage = null, int? errorSeverity = null, string operation = null, Guid? operationId = null, int? percentComplete = null, int? requestedDatabaseDtuMax = null, int? requestedDatabaseDtuMin = null, int? requestedDtu = null, string requestedElasticPoolName = null, long? requestedStorageLimitInGB = null, string elasticPoolName = null, string serverName = null, DateTimeOffset? startOn = null, string state = null, int? requestedStorageLimitInMB = null, int? requestedDatabaseDtuGuarantee = null, int? requestedDatabaseDtuCap = null, int? requestedDtuGuarantee = null)
{
return new ElasticPoolActivity(
id,
name,
resourceType,
systemData,
location,
endOn,
errorCode,
errorMessage,
errorSeverity,
operation,
operationId,
percentComplete,
requestedDatabaseDtuMax,
requestedDatabaseDtuMin,
requestedDtu,
requestedElasticPoolName,
requestedStorageLimitInGB,
elasticPoolName,
serverName,
startOn,
state,
requestedStorageLimitInMB,
requestedDatabaseDtuGuarantee,
requestedDatabaseDtuCap,
requestedDtuGuarantee,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.ElasticPoolDatabaseActivity"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="location"> The geo-location where the resource lives. </param>
/// <param name="databaseName"> The database name. </param>
/// <param name="endOn"> The time the operation finished (ISO8601 format). </param>
/// <param name="errorCode"> The error code if available. </param>
/// <param name="errorMessage"> The error message if available. </param>
/// <param name="errorSeverity"> The error severity if available. </param>
/// <param name="operation"> The operation name. </param>
/// <param name="operationId"> The unique operation ID. </param>
/// <param name="percentComplete"> The percentage complete if available. </param>
/// <param name="requestedElasticPoolName"> The name for the elastic pool the database is moving into if available. </param>
/// <param name="currentElasticPoolName"> The name of the current elastic pool the database is in if available. </param>
/// <param name="currentServiceObjective"> The name of the current service objective if available. </param>
/// <param name="requestedServiceObjective"> The name of the requested service objective if available. </param>
/// <param name="serverName"> The name of the server the elastic pool is in. </param>
/// <param name="startOn"> The time the operation started (ISO8601 format). </param>
/// <param name="state"> The current state of the operation. </param>
/// <returns> A new <see cref="Models.ElasticPoolDatabaseActivity"/> instance for mocking. </returns>
public static ElasticPoolDatabaseActivity ElasticPoolDatabaseActivity(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, AzureLocation? location = null, string databaseName = null, DateTimeOffset? endOn = null, int? errorCode = null, string errorMessage = null, int? errorSeverity = null, string operation = null, Guid? operationId = null, int? percentComplete = null, string requestedElasticPoolName = null, string currentElasticPoolName = null, string currentServiceObjective = null, string requestedServiceObjective = null, string serverName = null, DateTimeOffset? startOn = null, string state = null)
{
return new ElasticPoolDatabaseActivity(
id,
name,
resourceType,
systemData,
location,
databaseName,
endOn,
errorCode,
errorMessage,
errorSeverity,
operation,
operationId,
percentComplete,
requestedElasticPoolName,
currentElasticPoolName,
currentServiceObjective,
requestedServiceObjective,
serverName,
startOn,
state,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.SqlServerUsage"/>. </summary>
/// <param name="name"> Name of the server usage metric. </param>
/// <param name="resourceName"> The name of the resource. </param>
/// <param name="displayName"> The metric display name. </param>
/// <param name="currentValue"> The current value of the metric. </param>
/// <param name="limit"> The current limit of the metric. </param>
/// <param name="unit"> The units of the metric. </param>
/// <param name="nextResetOn"> The next reset time for the metric (ISO8601 format). </param>
/// <returns> A new <see cref="Models.SqlServerUsage"/> instance for mocking. </returns>
public static SqlServerUsage SqlServerUsage(string name = null, string resourceName = null, string displayName = null, double? currentValue = null, double? limit = null, string unit = null, DateTimeOffset? nextResetOn = null)
{
return new SqlServerUsage(
name,
resourceName,
displayName,
currentValue,
limit,
unit,
nextResetOn,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlAdvisorData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="kind"> Resource kind. </param>
/// <param name="location"> Resource location. </param>
/// <param name="advisorStatus"> Gets the status of availability of this advisor to customers. Possible values are 'GA', 'PublicPreview', 'LimitedPublicPreview' and 'PrivatePreview'. </param>
/// <param name="autoExecuteStatus"> Gets the auto-execute status (whether to let the system execute the recommendations) of this advisor. Possible values are 'Enabled' and 'Disabled'. </param>
/// <param name="autoExecuteStatusInheritedFrom"> Gets the resource from which current value of auto-execute status is inherited. Auto-execute status can be set on (and inherited from) different levels in the resource hierarchy. Possible values are 'Subscription', 'Server', 'ElasticPool', 'Database' and 'Default' (when status is not explicitly set on any level). </param>
/// <param name="recommendationsStatus"> Gets that status of recommendations for this advisor and reason for not having any recommendations. Possible values include, but are not limited to, 'Ok' (Recommendations available),LowActivity (not enough workload to analyze), 'DbSeemsTuned' (Database is doing well), etc. </param>
/// <param name="lastCheckedOn"> Gets the time when the current resource was analyzed for recommendations by this advisor. </param>
/// <param name="recommendedActions"> Gets the recommended actions for this advisor. </param>
/// <returns> A new <see cref="Sql.SqlAdvisorData"/> instance for mocking. </returns>
public static SqlAdvisorData SqlAdvisorData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string kind = null, AzureLocation? location = null, SqlAdvisorStatus? advisorStatus = null, AutoExecuteStatus? autoExecuteStatus = null, AutoExecuteStatusInheritedFrom? autoExecuteStatusInheritedFrom = null, string recommendationsStatus = null, DateTimeOffset? lastCheckedOn = null, IEnumerable<RecommendedActionData> recommendedActions = null)
{
recommendedActions ??= new List<RecommendedActionData>();
return new SqlAdvisorData(
id,
name,
resourceType,
systemData,
kind,
location,
advisorStatus,
autoExecuteStatus,
autoExecuteStatusInheritedFrom,
recommendationsStatus,
lastCheckedOn,
recommendedActions?.ToList(),
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.RecommendedActionData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="kind"> Resource kind. </param>
/// <param name="location"> Resource location. </param>
/// <param name="recommendationReason"> Gets the reason for recommending this action. e.g., DuplicateIndex. </param>
/// <param name="validSince"> Gets the time since when this recommended action is valid. </param>
/// <param name="lastRefresh"> Gets time when this recommended action was last refreshed. </param>
/// <param name="state"> Gets the info of the current state the recommended action is in. </param>
/// <param name="isExecutableAction"> Gets if this recommended action is actionable by user. </param>
/// <param name="isRevertableAction"> Gets if changes applied by this recommended action can be reverted by user. </param>
/// <param name="isArchivedAction"> Gets if this recommended action was suggested some time ago but user chose to ignore this and system added a new recommended action again. </param>
/// <param name="executeActionStartOn"> Gets the time when system started applying this recommended action on the user resource. e.g., index creation start time. </param>
/// <param name="executeActionDuration"> Gets the time taken for applying this recommended action on user resource. e.g., time taken for index creation. </param>
/// <param name="revertActionStartOn"> Gets the time when system started reverting changes of this recommended action on user resource. e.g., time when index drop is executed. </param>
/// <param name="revertActionDuration"> Gets the time taken for reverting changes of this recommended action on user resource. e.g., time taken for dropping the created index. </param>
/// <param name="executeActionInitiatedBy"> Gets if approval for applying this recommended action was given by user/system. </param>
/// <param name="executeActionInitiatedOn"> Gets the time when this recommended action was approved for execution. </param>
/// <param name="revertActionInitiatedBy"> Gets if approval for reverting this recommended action was given by user/system. </param>
/// <param name="revertActionInitiatedOn"> Gets the time when this recommended action was approved for revert. </param>
/// <param name="score"> Gets the impact of this recommended action. Possible values are 1 - Low impact, 2 - Medium Impact and 3 - High Impact. </param>
/// <param name="implementationDetails"> Gets the implementation details of this recommended action for user to apply it manually. </param>
/// <param name="errorDetails"> Gets the error details if and why this recommended action is put to error state. </param>
/// <param name="estimatedImpact"> Gets the estimated impact info for this recommended action e.g., Estimated CPU gain, Estimated Disk Space change. </param>
/// <param name="observedImpact"> Gets the observed/actual impact info for this recommended action e.g., Actual CPU gain, Actual Disk Space change. </param>
/// <param name="timeSeries"> Gets the time series info of metrics for this recommended action e.g., CPU consumption time series. </param>
/// <param name="linkedObjects"> Gets the linked objects, if any. </param>
/// <param name="details"> Gets additional details specific to this recommended action. </param>
/// <returns> A new <see cref="Sql.RecommendedActionData"/> instance for mocking. </returns>
public static RecommendedActionData RecommendedActionData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string kind = null, AzureLocation? location = null, string recommendationReason = null, DateTimeOffset? validSince = null, DateTimeOffset? lastRefresh = null, RecommendedActionStateInfo state = null, bool? isExecutableAction = null, bool? isRevertableAction = null, bool? isArchivedAction = null, DateTimeOffset? executeActionStartOn = null, TimeSpan? executeActionDuration = null, DateTimeOffset? revertActionStartOn = null, TimeSpan? revertActionDuration = null, RecommendedActionInitiatedBy? executeActionInitiatedBy = null, DateTimeOffset? executeActionInitiatedOn = null, RecommendedActionInitiatedBy? revertActionInitiatedBy = null, DateTimeOffset? revertActionInitiatedOn = null, int? score = null, RecommendedActionImplementationInfo implementationDetails = null, RecommendedActionErrorInfo errorDetails = null, IEnumerable<RecommendedActionImpactRecord> estimatedImpact = null, IEnumerable<RecommendedActionImpactRecord> observedImpact = null, IEnumerable<RecommendedActionMetricInfo> timeSeries = null, IEnumerable<string> linkedObjects = null, IReadOnlyDictionary<string, BinaryData> details = null)
{
estimatedImpact ??= new List<RecommendedActionImpactRecord>();
observedImpact ??= new List<RecommendedActionImpactRecord>();
timeSeries ??= new List<RecommendedActionMetricInfo>();
linkedObjects ??= new List<string>();
details ??= new Dictionary<string, BinaryData>();
return new RecommendedActionData(
id,
name,
resourceType,
systemData,
kind,
location,
recommendationReason,
validSince,
lastRefresh,
state,
isExecutableAction,
isRevertableAction,
isArchivedAction,
executeActionStartOn,
executeActionDuration,
revertActionStartOn,
revertActionDuration,
executeActionInitiatedBy,
executeActionInitiatedOn,
revertActionInitiatedBy,
revertActionInitiatedOn,
score,
implementationDetails,
errorDetails,
estimatedImpact?.ToList(),
observedImpact?.ToList(),
timeSeries?.ToList(),
linkedObjects?.ToList(),
details,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.RecommendedActionStateInfo"/>. </summary>
/// <param name="currentValue"> Current state the recommended action is in. Some commonly used states are: Active -> recommended action is active and no action has been taken yet. Pending -> recommended action is approved for and is awaiting execution. Executing -> recommended action is being applied on the user database. Verifying -> recommended action was applied and is being verified of its usefulness by the system. Success -> recommended action was applied and improvement found during verification. Pending Revert -> verification found little or no improvement so recommended action is queued for revert or user has manually reverted. Reverting -> changes made while applying recommended action are being reverted on the user database. Reverted -> successfully reverted the changes made by recommended action on user database. Ignored -> user explicitly ignored/discarded the recommended action. </param>
/// <param name="actionInitiatedBy"> Gets who initiated the execution of this recommended action. Possible Value are: User -> When user explicity notified system to apply the recommended action. System -> When auto-execute status of this advisor was set to 'Enabled', in which case the system applied it. </param>
/// <param name="lastModified"> Gets the time when the state was last modified. </param>
/// <returns> A new <see cref="Models.RecommendedActionStateInfo"/> instance for mocking. </returns>
public static RecommendedActionStateInfo RecommendedActionStateInfo(RecommendedActionCurrentState currentValue = default, RecommendedActionInitiatedBy? actionInitiatedBy = null, DateTimeOffset? lastModified = null)
{
return new RecommendedActionStateInfo(currentValue, actionInitiatedBy, lastModified, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.RecommendedActionImplementationInfo"/>. </summary>
/// <param name="method"> Gets the method in which this recommended action can be manually implemented. e.g., TSql, AzurePowerShell. </param>
/// <param name="script"> Gets the manual implementation script. e.g., T-SQL script that could be executed on the database. </param>
/// <returns> A new <see cref="Models.RecommendedActionImplementationInfo"/> instance for mocking. </returns>
public static RecommendedActionImplementationInfo RecommendedActionImplementationInfo(ImplementationMethod? method = null, string script = null)
{
return new RecommendedActionImplementationInfo(method, script, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.RecommendedActionErrorInfo"/>. </summary>
/// <param name="errorCode"> Gets the reason why the recommended action was put to error state. e.g., DatabaseHasQdsOff, IndexAlreadyExists. </param>
/// <param name="isRetryable"> Gets whether the error could be ignored and recommended action could be retried. Possible values are: Yes/No. </param>
/// <returns> A new <see cref="Models.RecommendedActionErrorInfo"/> instance for mocking. </returns>
public static RecommendedActionErrorInfo RecommendedActionErrorInfo(string errorCode = null, ActionRetryableState? isRetryable = null)
{
return new RecommendedActionErrorInfo(errorCode, isRetryable, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.RecommendedActionImpactRecord"/>. </summary>
/// <param name="dimensionName"> Gets the name of the impact dimension. e.g., CPUChange, DiskSpaceChange, NumberOfQueriesAffected. </param>
/// <param name="unit"> Gets the name of the impact dimension. e.g., CPUChange, DiskSpaceChange, NumberOfQueriesAffected. </param>
/// <param name="absoluteValue"> Gets the absolute value of this dimension if applicable. e.g., Number of Queries affected. </param>
/// <param name="changeValueAbsolute"> Gets the absolute change in the value of this dimension. e.g., Absolute Disk space change in Megabytes. </param>
/// <param name="changeValueRelative"> Gets the relative change in the value of this dimension. e.g., Relative Disk space change in Percentage. </param>
/// <returns> A new <see cref="Models.RecommendedActionImpactRecord"/> instance for mocking. </returns>
public static RecommendedActionImpactRecord RecommendedActionImpactRecord(string dimensionName = null, string unit = null, double? absoluteValue = null, double? changeValueAbsolute = null, double? changeValueRelative = null)
{
return new RecommendedActionImpactRecord(
dimensionName,
unit,
absoluteValue,
changeValueAbsolute,
changeValueRelative,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.RecommendedActionMetricInfo"/>. </summary>
/// <param name="metricName"> Gets the name of the metric. e.g., CPU, Number of Queries. </param>
/// <param name="unit"> Gets the unit in which metric is measured. e.g., DTU, Frequency. </param>
/// <param name="timeGrain"> Gets the duration of time interval for the value given by this MetricInfo. e.g., PT1H (1 hour). </param>
/// <param name="startOn"> Gets the start time of time interval given by this MetricInfo. </param>
/// <param name="value"> Gets the value of the metric in the time interval given by this MetricInfo. </param>
/// <returns> A new <see cref="Models.RecommendedActionMetricInfo"/> instance for mocking. </returns>
public static RecommendedActionMetricInfo RecommendedActionMetricInfo(string metricName = null, string unit = null, string timeGrain = null, DateTimeOffset? startOn = null, double? value = null)
{
return new RecommendedActionMetricInfo(
metricName,
unit,
timeGrain,
startOn,
value,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlDatabaseAutomaticTuningData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="desiredState"> Automatic tuning desired state. </param>
/// <param name="actualState"> Automatic tuning actual state. </param>
/// <param name="options"> Automatic tuning options definition. </param>
/// <returns> A new <see cref="Sql.SqlDatabaseAutomaticTuningData"/> instance for mocking. </returns>
public static SqlDatabaseAutomaticTuningData SqlDatabaseAutomaticTuningData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, AutomaticTuningMode? desiredState = null, AutomaticTuningMode? actualState = null, IDictionary<string, AutomaticTuningOptions> options = null)
{
options ??= new Dictionary<string, AutomaticTuningOptions>();
return new SqlDatabaseAutomaticTuningData(
id,
name,
resourceType,
systemData,
desiredState,
actualState,
options,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.AutomaticTuningOptions"/>. </summary>
/// <param name="desiredState"> Automatic tuning option desired state. </param>
/// <param name="actualState"> Automatic tuning option actual state. </param>
/// <param name="reasonCode"> Reason code if desired and actual state are different. </param>
/// <param name="reasonDesc"> Reason description if desired and actual state are different. </param>
/// <returns> A new <see cref="Models.AutomaticTuningOptions"/> instance for mocking. </returns>
public static AutomaticTuningOptions AutomaticTuningOptions(AutomaticTuningOptionModeDesired? desiredState = null, AutomaticTuningOptionModeActual? actualState = null, int? reasonCode = null, AutomaticTuningDisabledReason? reasonDesc = null)
{
return new AutomaticTuningOptions(desiredState, actualState, reasonCode, reasonDesc, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.DatabaseColumnData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="columnType"> The column data type. </param>
/// <param name="temporalType"> The table temporal type. </param>
/// <param name="isMemoryOptimized"> Whether or not the column belongs to a memory optimized table. </param>
/// <param name="isComputed"> Whether or not the column is computed. </param>
/// <returns> A new <see cref="Sql.DatabaseColumnData"/> instance for mocking. </returns>
public static DatabaseColumnData DatabaseColumnData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, SqlColumnDataType? columnType = null, TableTemporalType? temporalType = null, bool? isMemoryOptimized = null, bool? isComputed = null)
{
return new DatabaseColumnData(
id,
name,
resourceType,
systemData,
columnType,
temporalType,
isMemoryOptimized,
isComputed,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.DatabaseSchemaData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <returns> A new <see cref="Sql.DatabaseSchemaData"/> instance for mocking. </returns>
public static DatabaseSchemaData DatabaseSchemaData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null)
{
return new DatabaseSchemaData(id, name, resourceType, systemData, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlDatabaseSecurityAlertPolicyData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="state"> Specifies the state of the policy, whether it is enabled or disabled or a policy has not been applied yet on the specific database. </param>
/// <param name="disabledAlerts"> Specifies an array of alerts that are disabled. Allowed values are: Sql_Injection, Sql_Injection_Vulnerability, Access_Anomaly, Data_Exfiltration, Unsafe_Action, Brute_Force. </param>
/// <param name="emailAddresses"> Specifies an array of e-mail addresses to which the alert is sent. </param>
/// <param name="sendToEmailAccountAdmins"> Specifies that the alert is sent to the account administrators. </param>
/// <param name="storageEndpoint"> Specifies the blob storage endpoint (e.g. https://MyAccount.blob.core.windows.net). This blob storage will hold all Threat Detection audit logs. </param>
/// <param name="storageAccountAccessKey"> Specifies the identifier key of the Threat Detection audit storage account. </param>
/// <param name="retentionDays"> Specifies the number of days to keep in the Threat Detection audit logs. </param>
/// <param name="createdOn"> Specifies the UTC creation time of the policy. </param>
/// <returns> A new <see cref="Sql.SqlDatabaseSecurityAlertPolicyData"/> instance for mocking. </returns>
public static SqlDatabaseSecurityAlertPolicyData SqlDatabaseSecurityAlertPolicyData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, SecurityAlertsPolicyState? state = null, IEnumerable<string> disabledAlerts = null, IEnumerable<string> emailAddresses = null, bool? sendToEmailAccountAdmins = null, string storageEndpoint = null, string storageAccountAccessKey = null, int? retentionDays = null, DateTimeOffset? createdOn = null)
{
disabledAlerts ??= new List<string>();
emailAddresses ??= new List<string>();
return new SqlDatabaseSecurityAlertPolicyData(
id,
name,
resourceType,
systemData,
state,
disabledAlerts?.ToList(),
emailAddresses?.ToList(),
sendToEmailAccountAdmins,
storageEndpoint,
storageAccountAccessKey,
retentionDays,
createdOn,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.DatabaseTableData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="temporalType"> The table temporal type. </param>
/// <param name="isMemoryOptimized"> Whether or not the table is memory optimized. </param>
/// <returns> A new <see cref="Sql.DatabaseTableData"/> instance for mocking. </returns>
public static DatabaseTableData DatabaseTableData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, TableTemporalType? temporalType = null, bool? isMemoryOptimized = null)
{
return new DatabaseTableData(
id,
name,
resourceType,
systemData,
temporalType,
isMemoryOptimized,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.DatabaseVulnerabilityAssessmentRuleBaselineData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="baselineResults"> The rule baseline result. </param>
/// <returns> A new <see cref="Sql.DatabaseVulnerabilityAssessmentRuleBaselineData"/> instance for mocking. </returns>
public static DatabaseVulnerabilityAssessmentRuleBaselineData DatabaseVulnerabilityAssessmentRuleBaselineData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, IEnumerable<DatabaseVulnerabilityAssessmentRuleBaselineItem> baselineResults = null)
{
baselineResults ??= new List<DatabaseVulnerabilityAssessmentRuleBaselineItem>();
return new DatabaseVulnerabilityAssessmentRuleBaselineData(
id,
name,
resourceType,
systemData,
baselineResults?.ToList(),
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.DatabaseVulnerabilityAssessmentData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="storageContainerPath"> A blob storage container path to hold the scan results (e.g. https://myStorage.blob.core.windows.net/VaScans/). It is required if server level vulnerability assessment policy doesn't set. </param>
/// <param name="storageContainerSasKey"> A shared access signature (SAS Key) that has write access to the blob container specified in 'storageContainerPath' parameter. If 'storageAccountAccessKey' isn't specified, StorageContainerSasKey is required. </param>
/// <param name="storageAccountAccessKey"> Specifies the identifier key of the storage account for vulnerability assessment scan results. If 'StorageContainerSasKey' isn't specified, storageAccountAccessKey is required. </param>
/// <param name="recurringScans"> The recurring scans settings. </param>
/// <returns> A new <see cref="Sql.DatabaseVulnerabilityAssessmentData"/> instance for mocking. </returns>
public static DatabaseVulnerabilityAssessmentData DatabaseVulnerabilityAssessmentData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string storageContainerPath = null, string storageContainerSasKey = null, string storageAccountAccessKey = null, VulnerabilityAssessmentRecurringScansProperties recurringScans = null)
{
return new DatabaseVulnerabilityAssessmentData(
id,
name,
resourceType,
systemData,
storageContainerPath,
storageContainerSasKey,
storageAccountAccessKey,
recurringScans,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.VulnerabilityAssessmentScanRecordData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="scanId"> The scan ID. </param>
/// <param name="triggerType"> The scan trigger type. </param>
/// <param name="state"> The scan status. </param>
/// <param name="startOn"> The scan start time (UTC). </param>
/// <param name="endOn"> The scan end time (UTC). </param>
/// <param name="errors"> The scan errors. </param>
/// <param name="storageContainerPath"> The scan results storage container path. </param>
/// <param name="numberOfFailedSecurityChecks"> The number of failed security checks. </param>
/// <returns> A new <see cref="Sql.VulnerabilityAssessmentScanRecordData"/> instance for mocking. </returns>
public static VulnerabilityAssessmentScanRecordData VulnerabilityAssessmentScanRecordData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string scanId = null, VulnerabilityAssessmentScanTriggerType? triggerType = null, VulnerabilityAssessmentScanState? state = null, DateTimeOffset? startOn = null, DateTimeOffset? endOn = null, IEnumerable<VulnerabilityAssessmentScanError> errors = null, string storageContainerPath = null, int? numberOfFailedSecurityChecks = null)
{
errors ??= new List<VulnerabilityAssessmentScanError>();
return new VulnerabilityAssessmentScanRecordData(
id,
name,
resourceType,
systemData,
scanId,
triggerType,
state,
startOn,
endOn,
errors?.ToList(),
storageContainerPath,
numberOfFailedSecurityChecks,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.VulnerabilityAssessmentScanError"/>. </summary>
/// <param name="code"> The error code. </param>
/// <param name="message"> The error message. </param>
/// <returns> A new <see cref="Models.VulnerabilityAssessmentScanError"/> instance for mocking. </returns>
public static VulnerabilityAssessmentScanError VulnerabilityAssessmentScanError(string code = null, string message = null)
{
return new VulnerabilityAssessmentScanError(code, message, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.DatabaseVulnerabilityAssessmentScansExport"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="exportedReportLocation"> Location of the exported report (e.g. https://myStorage.blob.core.windows.net/VaScans/scans/serverName/databaseName/scan_scanId.xlsx). </param>
/// <returns> A new <see cref="Models.DatabaseVulnerabilityAssessmentScansExport"/> instance for mocking. </returns>
public static DatabaseVulnerabilityAssessmentScansExport DatabaseVulnerabilityAssessmentScansExport(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string exportedReportLocation = null)
{
return new DatabaseVulnerabilityAssessmentScansExport(
id,
name,
resourceType,
systemData,
exportedReportLocation,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.DataWarehouseUserActivityData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="activeQueriesCount"> Count of running and suspended queries. </param>
/// <returns> A new <see cref="Sql.DataWarehouseUserActivityData"/> instance for mocking. </returns>
public static DataWarehouseUserActivityData DataWarehouseUserActivityData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, int? activeQueriesCount = null)
{
return new DataWarehouseUserActivityData(
id,
name,
resourceType,
systemData,
activeQueriesCount,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.DeletedServerData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="version"> The version of the deleted server. </param>
/// <param name="deletedOn"> The deletion time of the deleted server. </param>
/// <param name="originalId"> The original ID of the server before deletion. </param>
/// <param name="fullyQualifiedDomainName"> The fully qualified domain name of the server. </param>
/// <returns> A new <see cref="Sql.DeletedServerData"/> instance for mocking. </returns>
public static DeletedServerData DeletedServerData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string version = null, DateTimeOffset? deletedOn = null, ResourceIdentifier originalId = null, string fullyQualifiedDomainName = null)
{
return new DeletedServerData(
id,
name,
resourceType,
systemData,
version,
deletedOn,
originalId,
fullyQualifiedDomainName,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.ElasticPoolOperationData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="elasticPoolName"> The name of the elastic pool the operation is being performed on. </param>
/// <param name="operation"> The name of operation. </param>
/// <param name="operationFriendlyName"> The friendly name of operation. </param>
/// <param name="percentComplete"> The percentage of the operation completed. </param>
/// <param name="serverName"> The name of the server. </param>
/// <param name="startOn"> The operation start time. </param>
/// <param name="state"> The operation state. </param>
/// <param name="errorCode"> The operation error code. </param>
/// <param name="errorDescription"> The operation error description. </param>
/// <param name="errorSeverity"> The operation error severity. </param>
/// <param name="isUserError"> Whether or not the error is a user error. </param>
/// <param name="estimatedCompleteOn"> The estimated completion time of the operation. </param>
/// <param name="description"> The operation description. </param>
/// <param name="isCancellable"> Whether the operation can be cancelled. </param>
/// <returns> A new <see cref="Models.ElasticPoolOperationData"/> instance for mocking. </returns>
public static ElasticPoolOperationData ElasticPoolOperationData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string elasticPoolName = null, string operation = null, string operationFriendlyName = null, int? percentComplete = null, string serverName = null, DateTimeOffset? startOn = null, string state = null, int? errorCode = null, string errorDescription = null, int? errorSeverity = null, bool? isUserError = null, DateTimeOffset? estimatedCompleteOn = null, string description = null, bool? isCancellable = null)
{
return new ElasticPoolOperationData(
id,
name,
resourceType,
systemData,
elasticPoolName,
operation,
operationFriendlyName,
percentComplete,
serverName,
startOn,
state,
errorCode,
errorDescription,
errorSeverity,
isUserError,
estimatedCompleteOn,
description,
isCancellable,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.EncryptionProtectorData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="kind"> Kind of encryption protector. This is metadata used for the Azure portal experience. </param>
/// <param name="location"> Resource location. </param>
/// <param name="subregion"> Subregion of the encryption protector. </param>
/// <param name="serverKeyName"> The name of the server key. </param>
/// <param name="serverKeyType"> The encryption protector type like 'ServiceManaged', 'AzureKeyVault'. </param>
/// <param name="uri"> The URI of the server key. </param>
/// <param name="thumbprint"> Thumbprint of the server key. </param>
/// <param name="isAutoRotationEnabled"> Key auto rotation opt-in flag. Either true or false. </param>
/// <returns> A new <see cref="Sql.EncryptionProtectorData"/> instance for mocking. </returns>
public static EncryptionProtectorData EncryptionProtectorData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string kind = null, AzureLocation? location = null, string subregion = null, string serverKeyName = null, SqlServerKeyType? serverKeyType = null, Uri uri = null, string thumbprint = null, bool? isAutoRotationEnabled = null)
{
return new EncryptionProtectorData(
id,
name,
resourceType,
systemData,
kind,
location,
subregion,
serverKeyName,
serverKeyType,
uri,
thumbprint,
isAutoRotationEnabled,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlFirewallRuleData"/>. </summary>
/// <param name="id"> Resource ID. </param>
/// <param name="name"> Resource name. </param>
/// <param name="resourceType"> Resource type. </param>
/// <param name="startIPAddress"> The start IP address of the firewall rule. Must be IPv4 format. Use value '0.0.0.0' for all Azure-internal IP addresses. </param>
/// <param name="endIPAddress"> The end IP address of the firewall rule. Must be IPv4 format. Must be greater than or equal to startIpAddress. Use value '0.0.0.0' for all Azure-internal IP addresses. </param>
/// <returns> A new <see cref="Sql.SqlFirewallRuleData"/> instance for mocking. </returns>
public static SqlFirewallRuleData SqlFirewallRuleData(ResourceIdentifier id = null, string name = null, ResourceType? resourceType = null, string startIPAddress = null, string endIPAddress = null)
{
return new SqlFirewallRuleData(
id,
name,
resourceType,
serializedAdditionalRawData: null,
startIPAddress,
endIPAddress);
}
/// <summary> Initializes a new instance of <see cref="Models.ProxyResourceWithWritableName"/>. </summary>
/// <param name="id"> Resource ID. </param>
/// <param name="name"> Resource name. </param>
/// <param name="resourceType"> Resource type. </param>
/// <returns> A new <see cref="Models.ProxyResourceWithWritableName"/> instance for mocking. </returns>
public static ProxyResourceWithWritableName ProxyResourceWithWritableName(ResourceIdentifier id = null, string name = null, ResourceType? resourceType = null)
{
return new ProxyResourceWithWritableName(id, name, resourceType, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Models.ResourceWithWritableName"/>. </summary>
/// <param name="id"> Resource ID. </param>
/// <param name="name"> Resource name. </param>
/// <param name="resourceType"> Resource type. </param>
/// <returns> A new <see cref="Models.ResourceWithWritableName"/> instance for mocking. </returns>
public static ResourceWithWritableName ResourceWithWritableName(ResourceIdentifier id = null, string name = null, ResourceType? resourceType = null)
{
return new ResourceWithWritableName(id, name, resourceType, serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlServerJobAgentData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="tags"> The tags. </param>
/// <param name="location"> The location. </param>
/// <param name="sku"> The name and tier of the SKU. </param>
/// <param name="databaseId"> Resource ID of the database to store job metadata in. </param>
/// <param name="state"> The state of the job agent. </param>
/// <returns> A new <see cref="Sql.SqlServerJobAgentData"/> instance for mocking. </returns>
public static SqlServerJobAgentData SqlServerJobAgentData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, IDictionary<string, string> tags = null, AzureLocation location = default, SqlSku sku = null, ResourceIdentifier databaseId = null, JobAgentState? state = null)
{
tags ??= new Dictionary<string, string>();
return new SqlServerJobAgentData(
id,
name,
resourceType,
systemData,
tags,
location,
sku,
databaseId,
state,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlServerJobCredentialData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="username"> The credential user name. </param>
/// <param name="password"> The credential password. </param>
/// <returns> A new <see cref="Sql.SqlServerJobCredentialData"/> instance for mocking. </returns>
public static SqlServerJobCredentialData SqlServerJobCredentialData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, string username = null, string password = null)
{
return new SqlServerJobCredentialData(
id,
name,
resourceType,
systemData,
username,
password,
serializedAdditionalRawData: null);
}
/// <summary> Initializes a new instance of <see cref="Sql.SqlServerJobExecutionData"/>. </summary>
/// <param name="id"> The id. </param>
/// <param name="name"> The name. </param>
/// <param name="resourceType"> The resourceType. </param>
/// <param name="systemData"> The systemData. </param>
/// <param name="jobVersion"> The job version number. </param>
/// <param name="stepName"> The job step name. </param>
/// <param name="stepId"> The job step id. </param>
/// <param name="jobExecutionId"> The unique identifier of the job execution. </param>
/// <param name="lifecycle"> The detailed state of the job execution. </param>
/// <param name="provisioningState"> The ARM provisioning state of the job execution. </param>
/// <param name="createOn"> The time that the job execution was created. </param>
/// <param name="startOn"> The time that the job execution started. </param>
/// <param name="endOn"> The time that the job execution completed. </param>
/// <param name="currentAttempts"> Number of times the job execution has been attempted. </param>
/// <param name="currentAttemptStartOn"> Start time of the current attempt. </param>
/// <param name="lastMessage"> The last status or error message. </param>
/// <param name="target"> The target that this execution is executed on. </param>
/// <returns> A new <see cref="Sql.SqlServerJobExecutionData"/> instance for mocking. </returns>
public static SqlServerJobExecutionData SqlServerJobExecutionData(ResourceIdentifier id = null, string name = null, ResourceType resourceType = default, SystemData systemData = null, int? jobVersion = null, string stepName = null, int? stepId = null, Guid? jobExecutionId = null, JobExecutionLifecycle? lifecycle = null, JobExecutionProvisioningState? provisioningState = null, DateTimeOffset? createOn = null, DateTimeOffset? startOn = null, DateTimeOffset? endOn = null, int? currentAttempts = null, DateTimeOffset? currentAttemptStartOn = null, string lastMessage = null, JobExecutionTarget target = null)
{
return new SqlServerJobExecutionData(
id,
name,
resourceType,