PowerTCP SSH and SFTP for .NET
ThreadingModel Enumeration




Specifies the available threading models.
Syntax
'Declaration
 
Public Enum ThreadingModel 
   Inherits System.Enum
'Usage
 
Dim instance As ThreadingModel
public enum ThreadingModel : System.Enum 
__value public enum ThreadingModel : public System.Enum 
public enum class ThreadingModel : public System.Enum 
Members
MemberDescription
ApartmentAsync Used for single-threaded apartment model environments when asynchronous non-blocking operation is desired.
ApartmentBlocking Used for single-threaded apartment model environments when blocking operation is desired.
Free Used for multi-threaded environments.
Remarks

ThreadingModel.Free - Using this model, all methods execute on the calling thread. This is the recommended usage for development environments where the application can use Start() to execute code directly on a worker thread, services, or any environment that does not have a UI thread. This is the recommended choice for native .NET applications and C++ applications where the component's COM interface is used.

ThreadingModel.ApartmentBlocking - Using this model, selected methods will spawn an internal thread to process the desired action while blocking and servicing messages on the UI thread. This is the recommended usage for apartment model environments (like VB6) that are simple in nature. These selected methods include documentation referencing this enumeration and the event they will raise upon completion.

ThreadingModel.ApartmentAsync - Using this model, selected methods will spawn an internal thread to process the desired action and immediately returns. This is the recommended usage for advanced apartment model environments (like VB6) that support events. These selected methods include documentation referencing this enumeration and the event they will raise upon completion.

Inheritance Hierarchy

System.Object
   System.ValueType
      System.Enum
         Dart.Ssh.ThreadingModel

See Also

Reference

Dart.Ssh Namespace


PowerTCP SSH and SFTP for .NET Documentation Version 7.0
© 2023 Dart Communications. All Rights Reserved.
Send comments on this topic