/// <summary> /// Initializes client properties. /// </summary> private void Initialize() { Labs = new LabsOperations(this); GlobalSchedules = new GlobalSchedulesOperations(this); ArtifactSources = new ArtifactSourcesOperations(this); ArmTemplates = new ArmTemplatesOperations(this); Artifacts = new ArtifactsOperations(this); Costs = new CostsOperations(this); CustomImages = new CustomImagesOperations(this); Formulas = new FormulasOperations(this); GalleryImages = new GalleryImagesOperations(this); NotificationChannels = new NotificationChannelsOperations(this); PolicySets = new PolicySetsOperations(this); Policies = new PoliciesOperations(this); Schedules = new SchedulesOperations(this); ServiceRunners = new ServiceRunnersOperations(this); Users = new UsersOperations(this); Disks = new DisksOperations(this); Environments = new EnvironmentsOperations(this); Secrets = new SecretsOperations(this); VirtualMachines = new VirtualMachinesOperations(this); VirtualMachineSchedules = new VirtualMachineSchedulesOperations(this); VirtualNetworks = new VirtualNetworksOperations(this); BaseUri = new System.Uri("https://management.azure.com"); ApiVersion = "2016-05-15"; 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() } }; CustomInitialize(); DeserializationSettings.Converters.Add(new TransformationJsonConverter()); DeserializationSettings.Converters.Add(new CloudErrorJsonConverter()); }
/// <summary> /// Initializes client properties. /// </summary> private void Initialize() { ProviderOperations = new ProviderOperations(this); GlobalUsers = new GlobalUsersOperations(this); LabAccounts = new LabAccountsOperations(this); Operations = new Operations(this); GalleryImages = new GalleryImagesOperations(this); Labs = new LabsOperations(this); EnvironmentSettings = new EnvironmentSettingsOperations(this); Environments = new EnvironmentsOperations(this); Users = new UsersOperations(this); BaseUri = new System.Uri("https://management.azure.com"); ApiVersion = "2018-10-15"; 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() } }; CustomInitialize(); DeserializationSettings.Converters.Add(new TransformationJsonConverter()); DeserializationSettings.Converters.Add(new CloudErrorJsonConverter()); }