Class SerialPortThreadFactory

java.lang.Object
com.fazecast.jSerialComm.SerialPortThreadFactory

public class SerialPortThreadFactory extends Object
This class is used to create internal jSerialComm threads. A user can call the set(ThreadFactory) method to override the way in which threads are created.
See Also:
  • Constructor Details

    • SerialPortThreadFactory

      public SerialPortThreadFactory()
  • Method Details

    • get

      public static ThreadFactory get()
      Returns the current ThreadFactory instance associated with this library.
      Returns:
      The current ThreadFactory instance.
      See Also:
    • set

      public static void set(ThreadFactory threadFactory)
      Allows a user to define a custom thread factory to be used by this library for creating new threads.

      Such a custom factory method may be used, for example, to set all new threads to run as daemons.

      Parameters:
      threadFactory - A user-defined custom thread factory instance.
      See Also: