/// <summary>
 /// Initializes client properties.
 /// </summary>
 private void Initialize()
 {
     Operations         = new Operations(this);
     AlertRules         = new AlertRulesOperations(this);
     Actions            = new ActionsOperations(this);
     AlertRuleTemplates = new AlertRuleTemplatesOperations(this);
     Bookmarks          = new BookmarksOperations(this);
     DataConnectors     = new DataConnectorsOperations(this);
     Incidents          = new IncidentsOperations(this);
     IncidentComments   = new IncidentCommentsOperations(this);
     BaseUri            = new System.Uri("https://management.azure.com");
     ApiVersion         = "2020-01-01";
     AcceptLanguage     = "en-US";
     LongRunningOperationRetryTimeout = 30;
     GenerateClientRequestId          = true;
     SerializationSettings            = new JsonSerializerSettings
     {
         Formatting            = Newtonsoft.Json.Formatting.Indented,
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     SerializationSettings.Converters.Add(new TransformationJsonConverter());
     DeserializationSettings = new JsonSerializerSettings
     {
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <AlertRule>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <AlertRule>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <AlertRuleTemplate>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <AlertRuleTemplate>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <DataConnector>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <DataConnector>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <Settings>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <Settings>("kind"));
     CustomInitialize();
     DeserializationSettings.Converters.Add(new TransformationJsonConverter());
     DeserializationSettings.Converters.Add(new CloudErrorJsonConverter());
 }
Esempio n. 2
0
 /// <summary>
 /// Initializes client properties.
 /// </summary>
 private void Initialize()
 {
     AlertRules                         = new AlertRulesOperations(this);
     Actions                            = new ActionsOperations(this);
     AlertRuleTemplates                 = new AlertRuleTemplatesOperations(this);
     AutomationRules                    = new AutomationRulesOperations(this);
     Incidents                          = new IncidentsOperations(this);
     Bookmarks                          = new BookmarksOperations(this);
     BookmarkRelations                  = new BookmarkRelationsOperations(this);
     Bookmark                           = new BookmarkOperations(this);
     IPGeodata                          = new IPGeodataOperations(this);
     DomainWhois                        = new DomainWhoisOperations(this);
     Entities                           = new EntitiesOperations(this);
     EntitiesGetTimeline                = new EntitiesGetTimelineOperations(this);
     EntitiesRelations                  = new EntitiesRelationsOperations(this);
     EntityRelations                    = new EntityRelationsOperations(this);
     EntityQueries                      = new EntityQueriesOperations(this);
     EntityQueryTemplates               = new EntityQueryTemplatesOperations(this);
     IncidentComments                   = new IncidentCommentsOperations(this);
     IncidentRelations                  = new IncidentRelationsOperations(this);
     Metadata                           = new MetadataOperations(this);
     OfficeConsents                     = new OfficeConsentsOperations(this);
     SentinelOnboardingStates           = new SentinelOnboardingStatesOperations(this);
     ProductSettings                    = new ProductSettingsOperations(this);
     SourceControl                      = new SourceControlOperations(this);
     SourceControls                     = new SourceControlsOperations(this);
     ThreatIntelligenceIndicator        = new ThreatIntelligenceIndicatorOperations(this);
     ThreatIntelligenceIndicators       = new ThreatIntelligenceIndicatorsOperations(this);
     ThreatIntelligenceIndicatorMetrics = new ThreatIntelligenceIndicatorMetricsOperations(this);
     Watchlists                         = new WatchlistsOperations(this);
     WatchlistItems                     = new WatchlistItemsOperations(this);
     DataConnectors                     = new DataConnectorsOperations(this);
     DataConnectorsCheckRequirements    = new DataConnectorsCheckRequirementsOperations(this);
     Operations                         = new Operations(this);
     BaseUri                            = new System.Uri("https://management.azure.com");
     ApiVersion                         = "2022-01-01-preview";
     AcceptLanguage                     = "en-US";
     LongRunningOperationRetryTimeout   = 30;
     GenerateClientRequestId            = true;
     SerializationSettings              = new JsonSerializerSettings
     {
         Formatting            = Newtonsoft.Json.Formatting.Indented,
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     SerializationSettings.Converters.Add(new TransformationJsonConverter());
     DeserializationSettings = new JsonSerializerSettings
     {
         DateFormatHandling    = Newtonsoft.Json.DateFormatHandling.IsoDateFormat,
         DateTimeZoneHandling  = Newtonsoft.Json.DateTimeZoneHandling.Utc,
         NullValueHandling     = Newtonsoft.Json.NullValueHandling.Ignore,
         ReferenceLoopHandling = Newtonsoft.Json.ReferenceLoopHandling.Serialize,
         ContractResolver      = new ReadOnlyJsonContractResolver(),
         Converters            = new List <JsonConverter>
         {
             new Iso8601TimeSpanConverter()
         }
     };
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <AlertRule>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <AlertRule>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <AlertRuleTemplate>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <AlertRuleTemplate>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <AutomationRuleCondition>("conditionType"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <AutomationRuleCondition>("conditionType"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <AutomationRuleAction>("actionType"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <AutomationRuleAction>("actionType"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <Entity>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <Entity>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <EntityTimelineItem>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <EntityTimelineItem>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <EntityQueryItem>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <EntityQueryItem>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <EntityQuery>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <EntityQuery>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <CustomEntityQuery>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <CustomEntityQuery>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <EntityQueryTemplate>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <EntityQueryTemplate>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <Settings>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <Settings>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <ThreatIntelligenceInformation>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <ThreatIntelligenceInformation>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <DataConnectorsCheckRequirements>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <DataConnectorsCheckRequirements>("kind"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <DataConnector>("kind"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <DataConnector>("kind"));
     CustomInitialize();
     DeserializationSettings.Converters.Add(new TransformationJsonConverter());
     DeserializationSettings.Converters.Add(new CloudErrorJsonConverter());
 }