/// <summary>
 /// Gets a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <SessionResource> GetAsync(this ISessionOperations operations, string resourceGroupName, string nodeName, string session, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(resourceGroupName, nodeName, session, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
示例#2
0
 /// <summary>
 /// Start Session
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='apiVersion'>
 /// Possible values include: '9'
 /// </param>
 /// <param name='deviceos'>
 /// Possible values include: 'ios'
 /// </param>
 /// <param name='devicehardwareId'>
 /// Possible values include: 'test'
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <Session> StartAsync(this ISessionOperations operations, string apiVersion = default(string), string deviceos = default(string), string devicehardwareId = default(string), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.StartWithHttpMessagesAsync(apiVersion, deviceos, devicehardwareId, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
示例#3
0
 /// <summary>
 /// Creates a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 /// <param name='userName'>
 /// User name to be used to connect to node
 /// </param>
 /// <param name='password'>
 /// Password associated with user name
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <SessionResource> CreateAsync(this ISessionOperations operations, string resourceGroupName, string nodeName, string session, string userName = default(string), string password = default(string), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(resourceGroupName, nodeName, session, userName, password, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
示例#4
0
 public DatingController(IWebHostEnvironment environment)
 {
     hostingEnvironment = environment;
     sessionFactory     = new SessionFactory(ds);
     messageSender      = new MessageSender(ds.GetSMTPSettings());
 }
 /// <summary>
 /// Creates a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 /// <param name='userName'>
 /// encrypted User name to be used to connect to node
 /// </param>
 /// <param name='password'>
 /// encrypted Password associated with user name
 /// </param>
 /// <param name='retentionPeriod'>
 /// session retention period. Possible values include: 'Session', 'Persistent'
 /// </param>
 /// <param name='credentialDataFormat'>
 /// credential data format. Possible values include: 'RsaEncrypted'
 /// </param>
 /// <param name='encryptionCertificateThumbprint'>
 /// encryption certificate thumbprint
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task <SessionResource> CreateAsync(this ISessionOperations operations, string resourceGroupName, string nodeName, string session, string userName = default(string), string password = default(string), RetentionPeriod?retentionPeriod = default(RetentionPeriod?), CredentialDataFormat?credentialDataFormat = default(CredentialDataFormat?), string encryptionCertificateThumbprint = default(string), System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(resourceGroupName, nodeName, session, userName, password, retentionPeriod, credentialDataFormat, encryptionCertificateThumbprint, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Creates a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 /// <param name='userName'>
 /// encrypted User name to be used to connect to node
 /// </param>
 /// <param name='password'>
 /// encrypted Password associated with user name
 /// </param>
 /// <param name='retentionPeriod'>
 /// session retention period. Possible values include: 'Session', 'Persistent'
 /// </param>
 /// <param name='credentialDataFormat'>
 /// credential data format. Possible values include: 'RsaEncrypted'
 /// </param>
 /// <param name='encryptionCertificateThumbprint'>
 /// encryption certificate thumbprint
 /// </param>
 public static SessionResource Create(this ISessionOperations operations, string resourceGroupName, string nodeName, string session, string userName = default(string), string password = default(string), RetentionPeriod?retentionPeriod = default(RetentionPeriod?), CredentialDataFormat?credentialDataFormat = default(CredentialDataFormat?), string encryptionCertificateThumbprint = default(string))
 {
     return(System.Threading.Tasks.Task.Factory.StartNew(s => ((ISessionOperations)s).CreateAsync(resourceGroupName, nodeName, session, userName, password, retentionPeriod, credentialDataFormat, encryptionCertificateThumbprint), operations, System.Threading.CancellationToken.None, System.Threading.Tasks.TaskCreationOptions.None, System.Threading.Tasks.TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
 /// <summary>
 /// Gets a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 public static SessionResource Get(this ISessionOperations operations, string resourceGroupName, string nodeName, string session)
 {
     return(System.Threading.Tasks.Task.Factory.StartNew(s => ((ISessionOperations)s).GetAsync(resourceGroupName, nodeName, session), operations, System.Threading.CancellationToken.None, System.Threading.Tasks.TaskCreationOptions.None, System.Threading.Tasks.TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
 /// <summary>
 /// Deletes a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async System.Threading.Tasks.Task DeleteAsync(this ISessionOperations operations, string resourceGroupName, string nodeName, string session, System.Threading.CancellationToken cancellationToken = default(System.Threading.CancellationToken))
 {
     await operations.DeleteWithHttpMessagesAsync(resourceGroupName, nodeName, session, null, cancellationToken).ConfigureAwait(false);
 }
示例#9
0
 /// <summary>
 /// Start Session
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='apiVersion'>
 /// Possible values include: '9'
 /// </param>
 /// <param name='deviceos'>
 /// Possible values include: 'ios'
 /// </param>
 /// <param name='devicehardwareId'>
 /// Possible values include: 'test'
 /// </param>
 public static Session Start(this ISessionOperations operations, string apiVersion = default(string), string deviceos = default(string), string devicehardwareId = default(string))
 {
     return(operations.StartAsync(apiVersion, deviceos, devicehardwareId).GetAwaiter().GetResult());
 }
示例#10
0
 /// <summary>
 /// Creates a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 /// <param name='userName'>
 /// User name to be used to connect to node
 /// </param>
 /// <param name='password'>
 /// Password associated with user name
 /// </param>
 public static SessionResource Create(this ISessionOperations operations, string resourceGroupName, string nodeName, string session, string userName = default(string), string password = default(string))
 {
     return(Task.Factory.StartNew(s => ((ISessionOperations)s).CreateAsync(resourceGroupName, nodeName, session, userName, password), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult());
 }
示例#11
0
 /// <summary>
 /// Deletes a session for a node
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='resourceGroupName'>
 /// The resource group name uniquely identifies the resource group within the
 /// user subscriptionId.
 /// </param>
 /// <param name='nodeName'>
 /// The node name (256 characters maximum).
 /// </param>
 /// <param name='session'>
 /// The sessionId from the user
 /// </param>
 public static void Delete(this ISessionOperations operations, string resourceGroupName, string nodeName, string session)
 {
     Task.Factory.StartNew(s => ((ISessionOperations)s).DeleteAsync(resourceGroupName, nodeName, session), operations, CancellationToken.None, TaskCreationOptions.None, TaskScheduler.Default).Unwrap().GetAwaiter().GetResult();
 }