/// <summary>
 /// get the Activity Logs for the Tenant. Everything that is applicable to the
 /// API to get the Activity Log for the subscription is applicable to this API
 /// (the parameters, $filter, etc.). One thing to point out here is that this
 /// API does *not* retrieve the logs at the individual subscription of the
 /// tenant but only surfaces the logs that were generated at the tenant level.
 /// The **$filter** is very restricted and allows only the following patterns.
 /// - List events for a resource group: $filter=eventTimestamp ge '&lt;Start
 /// Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq
 /// 'Admin, Operation' and resourceGroupName eq '&lt;ResourceGroupName&gt;'. -
 /// List events for resource: $filter=eventTimestamp ge '&lt;Start Time&gt;'
 /// and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation' and resourceUri eq '&lt;ResourceURI&gt;'. - List events for a
 /// subscription: $filter=eventTimestamp ge '&lt;Start Time&gt;' and
 /// eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation'. - List evetns for a resource provider: $filter=eventTimestamp
 /// ge '&lt;Start Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and
 /// eventChannels eq 'Admin, Operation' and resourceProvider eq
 /// '&lt;ResourceProviderName&gt;'. - List events for a correlation Id:
 /// api-version=2014-04-01&amp;$filter=eventTimestamp ge
 /// '2014-07-16T04:36:37.6407898Z' and eventTimestamp le
 /// '2014-07-20T04:36:37.6407898Z' and eventChannels eq 'Admin, Operation' and
 /// correlationId eq '&lt;CorrelationID&gt;'. No other syntax is allowed.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='odataQuery'>
 /// OData parameters to apply to the operation.
 /// </param>
 /// <param name='select'>
 /// Used to fetch events with only the given properties. The filter is a comma
 /// separated list of property names to be returned. Possible values are:
 /// authorization, channels, claims, correlationId, description, eventDataId,
 /// eventName, eventTimestamp, httpRequest, level, operationId, operationName,
 /// properties, resourceGroupName, resourceProviderName, resourceId, status,
 /// submissionTimestamp, subStatus, subscriptionId
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <Microsoft.Rest.Azure.IPage <EventData> > ListAsync(this ITenantEventsOperations operations, Microsoft.Rest.Azure.OData.ODataQuery <EventData> odataQuery = default(Microsoft.Rest.Azure.OData.ODataQuery <EventData>), string select = default(string), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
 {
     using (var _result = await operations.ListWithHttpMessagesAsync(odataQuery, select, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// get the Activity Logs for the Tenant. Everything that is applicable to the
 /// API to get the Activity Log for the subscription is applicable to this API
 /// (the parameters, $filter, etc.). One thing to point out here is that this
 /// API does *not* retrieve the logs at the individual subscription of the
 /// tenant but only surfaces the logs that were generated at the tenant level.
 /// The **$filter** is very restricted and allows only the following patterns.
 /// - List events for a resource group: $filter=eventTimestamp ge '&lt;Start
 /// Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq
 /// 'Admin, Operation' and resourceGroupName eq '&lt;ResourceGroupName&gt;'. -
 /// List events for resource: $filter=eventTimestamp ge '&lt;Start Time&gt;'
 /// and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation' and resourceUri eq '&lt;ResourceURI&gt;'. - List events for a
 /// subscription: $filter=eventTimestamp ge '&lt;Start Time&gt;' and
 /// eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation'. - List evetns for a resource provider: $filter=eventTimestamp
 /// ge '&lt;Start Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and
 /// eventChannels eq 'Admin, Operation' and resourceProvider eq
 /// '&lt;ResourceProviderName&gt;'. - List events for a correlation Id:
 /// api-version=2014-04-01&amp;$filter=eventTimestamp ge
 /// '2014-07-16T04:36:37.6407898Z' and eventTimestamp le
 /// '2014-07-20T04:36:37.6407898Z' and eventChannels eq 'Admin, Operation' and
 /// correlationId eq '&lt;CorrelationID&gt;'. No other syntax is allowed.
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='odataQuery'>
 /// OData parameters to apply to the operation.
 /// </param>
 /// <param name='select'>
 /// Used to fetch events with only the given properties. The filter is a comma
 /// separated list of property names to be returned. Possible values are:
 /// authorization, channels, claims, correlationId, description, eventDataId,
 /// eventName, eventTimestamp, httpRequest, level, operationId, operationName,
 /// properties, resourceGroupName, resourceProviderName, resourceId, status,
 /// submissionTimestamp, subStatus, subscriptionId
 /// </param>
 public static Microsoft.Rest.Azure.IPage <EventData> List(this ITenantEventsOperations operations, Microsoft.Rest.Azure.OData.ODataQuery <EventData> odataQuery = default(Microsoft.Rest.Azure.OData.ODataQuery <EventData>), string select = default(string))
 {
     return(System.Threading.Tasks.Task.Factory.StartNew(s => ((ITenantEventsOperations)s).ListAsync(odataQuery, select), operations, System.Threading.CancellationToken.None, System.Threading.Tasks.TaskCreationOptions.None, System.Threading.Tasks.TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
 /// <summary>
 /// get the Activity Logs for the Tenant. Everything that is applicable to the
 /// API to get the Activity Log for the subscription is applicable to this API
 /// (the parameters, $filter, etc.). One thing to point out here is that this
 /// API does *not* retrieve the logs at the individual subscription of the
 /// tenant but only surfaces the logs that were generated at the tenant level.
 /// The **$filter** is very restricted and allows only the following patterns.
 /// - List events for a resource group: $filter=eventTimestamp ge '&lt;Start
 /// Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq
 /// 'Admin, Operation' and resourceGroupName eq '&lt;ResourceGroupName&gt;'. -
 /// List events for resource: $filter=eventTimestamp ge '&lt;Start Time&gt;'
 /// and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation' and resourceUri eq '&lt;ResourceURI&gt;'. - List events for a
 /// subscription: $filter=eventTimestamp ge '&lt;Start Time&gt;' and
 /// eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation'. - List evetns for a resource provider: $filter=eventTimestamp
 /// ge '&lt;Start Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and
 /// eventChannels eq 'Admin, Operation' and resourceProvider eq
 /// '&lt;ResourceProviderName&gt;'. - List events for a correlation Id:
 /// api-version=2014-04-01&amp;$filter=eventTimestamp ge
 /// '2014-07-16T04:36:37.6407898Z' and eventTimestamp le
 /// '2014-07-20T04:36:37.6407898Z' and eventChannels eq 'Admin, Operation' and
 /// correlationId eq '&lt;CorrelationID&gt;'. No other syntax is allowed.
 /// </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 <Microsoft.Rest.Azure.IPage <EventData> > ListNextAsync(this ITenantEventsOperations operations, string nextPageLink, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
 {
     using (var _result = await operations.ListNextWithHttpMessagesAsync(nextPageLink, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// get the Activity Logs for the Tenant. Everything that is applicable to the
 /// API to get the Activity Log for the subscription is applicable to this API
 /// (the parameters, $filter, etc.). One thing to point out here is that this
 /// API does *not* retrieve the logs at the individual subscription of the
 /// tenant but only surfaces the logs that were generated at the tenant level.
 /// The **$filter** is very restricted and allows only the following patterns.
 /// - List events for a resource group: $filter=eventTimestamp ge '&lt;Start
 /// Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq
 /// 'Admin, Operation' and resourceGroupName eq '&lt;ResourceGroupName&gt;'. -
 /// List events for resource: $filter=eventTimestamp ge '&lt;Start Time&gt;'
 /// and eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation' and resourceUri eq '&lt;ResourceURI&gt;'. - List events for a
 /// subscription: $filter=eventTimestamp ge '&lt;Start Time&gt;' and
 /// eventTimestamp le '&lt;End Time&gt;' and eventChannels eq 'Admin,
 /// Operation'. - List evetns for a resource provider: $filter=eventTimestamp
 /// ge '&lt;Start Time&gt;' and eventTimestamp le '&lt;End Time&gt;' and
 /// eventChannels eq 'Admin, Operation' and resourceProvider eq
 /// '&lt;ResourceProviderName&gt;'. - List events for a correlation Id:
 /// api-version=2014-04-01&amp;$filter=eventTimestamp ge
 /// '2014-07-16T04:36:37.6407898Z' and eventTimestamp le
 /// '2014-07-20T04:36:37.6407898Z' and eventChannels eq 'Admin, Operation' and
 /// correlationId eq '&lt;CorrelationID&gt;'. No other syntax is allowed.
 /// </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 Microsoft.Rest.Azure.IPage <EventData> ListNext(this ITenantEventsOperations operations, string nextPageLink)
 {
     return(System.Threading.Tasks.Task.Factory.StartNew(s => ((ITenantEventsOperations)s).ListNextAsync(nextPageLink), operations, System.Threading.CancellationToken.None, System.Threading.Tasks.TaskCreationOptions.None, System.Threading.Tasks.TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }