/// <summary>
 /// Gets all legal agreements that user needs to accept before purchasing a
 /// domain.
 /// </summary>
 /// <remarks>
 /// Description for Gets all legal agreements that user needs to accept before
 /// purchasing a domain.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top-level domain.
 /// </param>
 /// <param name='agreementOption'>
 /// Domain agreement options.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <TldLegalAgreement> > ListAgreementsAsync(this ITopLevelDomainsOperations operations, string name, TopLevelDomainAgreementOption agreementOption, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListAgreementsWithHttpMessagesAsync(name, agreementOption, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Get details of a top-level domain.
 /// </summary>
 /// <remarks>
 /// Description for Get details of a top-level domain.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top-level domain.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <TopLevelDomain> GetAsync(this ITopLevelDomainsOperations operations, string name, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(name, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Get all top-level domains supported for registration.
 /// </summary>
 /// <remarks>
 /// Description for Get all top-level domains supported for registration.
 /// </remarks>
 /// <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 <TopLevelDomain> > ListNextAsync(this ITopLevelDomainsOperations operations, string nextPageLink, CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
Exemplo n.º 4
0
 /// <summary>
 /// Gets all legal agreements that user needs to accept before purchasing a
 /// domain.
 /// </summary>
 /// <remarks>
 /// Gets all legal agreements that user needs to accept before purchasing a
 /// domain.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top-level domain.
 /// </param>
 /// <param name='includePrivacy'>
 /// If &lt;code&gt;true&lt;/code&gt;, then the list of agreements will include
 /// agreements for domain privacy as well; otherwise,
 /// &lt;code&gt;false&lt;/code&gt;.
 /// </param>
 /// <param name='forTransfer'>
 /// If &lt;code&gt;true&lt;/code&gt;, then the list of agreements will include
 /// agreements for domain transfer as well; otherwise,
 /// &lt;code&gt;false&lt;/code&gt;.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <IPage <TldLegalAgreement> > ListAgreementsAsync(this ITopLevelDomainsOperations operations, string name, bool?includePrivacy = default(bool?), bool?forTransfer = default(bool?), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.ListAgreementsWithHttpMessagesAsync(name, includePrivacy, forTransfer, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Get details of a top-level domain.
 /// </summary>
 /// <remarks>
 /// Description for Get details of a top-level domain.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top-level domain.
 /// </param>
 public static TopLevelDomain Get(this ITopLevelDomainsOperations operations, string name)
 {
     return(operations.GetAsync(name).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Get all top-level domains supported for registration.
 /// </summary>
 /// <remarks>
 /// Description for Get all top-level domains supported for registration.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 public static IPage <TopLevelDomain> List(this ITopLevelDomainsOperations operations)
 {
     return(operations.ListAsync().GetAwaiter().GetResult());
 }
 /// <summary>
 /// Gets all legal agreements that user needs to accept before purchasing a
 /// domain.
 /// </summary>
 /// <remarks>
 /// Description for Gets all legal agreements that user needs to accept before
 /// purchasing a domain.
 /// </remarks>
 /// <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 <TldLegalAgreement> ListAgreementsNext(this ITopLevelDomainsOperations operations, string nextPageLink)
 {
     return(operations.ListAgreementsNextAsync(nextPageLink).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Gets all legal agreements that user needs to accept before purchasing a
 /// domain.
 /// </summary>
 /// <remarks>
 /// Description for Gets all legal agreements that user needs to accept before
 /// purchasing a domain.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top-level domain.
 /// </param>
 /// <param name='agreementOption'>
 /// Domain agreement options.
 /// </param>
 public static IPage <TldLegalAgreement> ListAgreements(this ITopLevelDomainsOperations operations, string name, TopLevelDomainAgreementOption agreementOption)
 {
     return(operations.ListAgreementsAsync(name, agreementOption).GetAwaiter().GetResult());
 }
Exemplo n.º 9
0
 /// <summary>
 /// Gets all legal agreements that user needs to accept before purchasing a
 /// domain.
 /// </summary>
 /// <remarks>
 /// Gets all legal agreements that user needs to accept before purchasing a
 /// domain.
 /// </remarks>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top-level domain.
 /// </param>
 /// <param name='includePrivacy'>
 /// If &lt;code&gt;true&lt;/code&gt;, then the list of agreements will include
 /// agreements for domain privacy as well; otherwise,
 /// &lt;code&gt;false&lt;/code&gt;.
 /// </param>
 /// <param name='forTransfer'>
 /// If &lt;code&gt;true&lt;/code&gt;, then the list of agreements will include
 /// agreements for domain transfer as well; otherwise,
 /// &lt;code&gt;false&lt;/code&gt;.
 /// </param>
 public static IPage <TldLegalAgreement> ListAgreements(this ITopLevelDomainsOperations operations, string name, bool?includePrivacy = default(bool?), bool?forTransfer = default(bool?))
 {
     return(operations.ListAgreementsAsync(name, includePrivacy, forTransfer).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Lists legal agreements that user needs to accept before purchasing domain
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top level domain
 /// </param>
 /// <param name='agreementOption'>
 /// Domain agreement options
 /// </param>
 public static TldLegalAgreementCollection ListTopLevelDomainAgreements(this ITopLevelDomainsOperations operations, string name, TopLevelDomainAgreementOption agreementOption)
 {
     return(Task.Factory.StartNew(s => ((ITopLevelDomainsOperations)s).ListTopLevelDomainAgreementsAsync(name, agreementOption), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
 /// <summary>
 /// Gets details of a top level domain
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='name'>
 /// Name of the top level domain
 /// </param>
 public static TopLevelDomain GetTopLevelDomain(this ITopLevelDomainsOperations operations, string name)
 {
     return(Task.Factory.StartNew(s => ((ITopLevelDomainsOperations)s).GetTopLevelDomainAsync(name), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }