Example #1
0
 /// <summary>
 /// Create a ModuleClient from individual parameters
 /// </summary>
 /// <param name="hostname">The fully-qualified DNS hostname of IoT Hub</param>
 /// <param name="gatewayHostname">The fully-qualified DNS hostname of Gateway</param>
 /// <param name="authenticationMethod">The authentication method that is used</param>
 /// <param name="transportType">The transportType used (Http1 or Amqp)</param>
 /// <returns>ModuleClient</returns>
 public static ModuleClient Create(string hostname, string gatewayHostname, IAuthenticationMethod authenticationMethod, TransportType transportType)
 {
     return(Create(() => ClientFactory.Create(hostname, gatewayHostname, authenticationMethod, transportType)));
 }
Example #2
0
 /// <summary>
 /// Create a DeviceClient from individual parameters
 /// </summary>
 /// <param name="hostname">The fully-qualified DNS hostname of IoT Hub</param>
 /// <param name="gatewayHostname">The fully-qualified DNS hostname of Gateway</param>
 /// <param name="authenticationMethod">The authentication method that is used</param>
 /// <param name="transportSettings">Prioritized list of transportTypes and their settings</param>
 /// <returns>DeviceClient</returns>
 public static DeviceClient Create(string hostname, string gatewayHostname, IAuthenticationMethod authenticationMethod,
                                   ITransportSettings[] transportSettings)
 {
     return(Create(() => ClientFactory.Create(hostname, gatewayHostname, authenticationMethod, transportSettings)));
 }
Example #3
0
 /// <summary>
 /// Create an Amqp ModuleClient from individual parameters
 /// </summary>
 /// <param name="hostname">The fully-qualified DNS hostname of IoT Hub</param>
 /// <param name="authenticationMethod">The authentication method that is used</param>
 /// <returns>ModuleClient</returns>
 public static ModuleClient Create(string hostname, IAuthenticationMethod authenticationMethod)
 {
     return(Create(() => ClientFactory.Create(hostname, authenticationMethod)));
 }