Exemplo n.º 1
0
 /// <summary>
 /// Lists all the edge nodes of a CDN service.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <EdgeNodeInner> > ListNextAsync(this IEdgeNodesOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemplo n.º 2
0
 /// <summary>
 /// Initializes client properties.
 /// </summary>
 private void Initialize()
 {
     Profiles       = new ProfilesOperations(this);
     Endpoints      = new EndpointsOperations(this);
     Origins        = new OriginsOperations(this);
     CustomDomains  = new CustomDomainsOperations(this);
     ResourceUsage  = new ResourceUsageOperations(this);
     Operations     = new Operations(this);
     EdgeNodes      = new EdgeNodesOperations(this);
     BaseUri        = new System.Uri("https://management.azure.com");
     ApiVersion     = "2017-10-12";
     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 <DeliveryRuleAction>("name"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <DeliveryRuleAction>("name"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <DeliveryRuleCondition>("name"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <DeliveryRuleCondition>("name"));
     SerializationSettings.Converters.Add(new PolymorphicSerializeJsonConverter <CustomDomainHttpsParameters>("certificateSource"));
     DeserializationSettings.Converters.Add(new PolymorphicDeserializeJsonConverter <CustomDomainHttpsParameters>("certificateSource"));
     CustomInitialize();
     DeserializationSettings.Converters.Add(new TransformationJsonConverter());
     DeserializationSettings.Converters.Add(new CloudErrorJsonConverter());
 }
Exemplo n.º 3
0
 /// <summary>
 /// Edgenodes are the global Point of Presence (POP) locations used to deliver
 /// CDN content to end users.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='nextPageLink'>
 /// The NextLink from the previous successful call to List operation.
 /// </param>
 public static IPage <EdgeNode> ListNext(this IEdgeNodesOperations operations, string nextPageLink)
 {
     return(operations.ListNextAsync(nextPageLink).GetAwaiter().GetResult());
 }
Exemplo n.º 4
0
 /// <summary>
 /// Edgenodes are the global Point of Presence (POP) locations used to deliver
 /// CDN content to end users.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 public static IPage <EdgeNode> List(this IEdgeNodesOperations operations)
 {
     return(operations.ListAsync().GetAwaiter().GetResult());
 }