Class SQSMessagingClientThreadFactory

  • All Implemented Interfaces:
    ThreadFactory

    public class SQSMessagingClientThreadFactory
    extends Object
    implements ThreadFactory
    Simple thread factory that supports ThreadGroups
    • Constructor Detail

      • SQSMessagingClientThreadFactory

        public SQSMessagingClientThreadFactory​(String taskName,
                                               boolean isDaemon)
      • SQSMessagingClientThreadFactory

        public SQSMessagingClientThreadFactory​(String taskName,
                                               boolean isDaemon,
                                               boolean createWithThreadGroup)
      • SQSMessagingClientThreadFactory

        public SQSMessagingClientThreadFactory​(String taskName,
                                               ThreadGroup threadGroup)
    • Method Detail

      • newThread

        public Thread newThread​(Runnable r)
        Constructs a new Thread. Initializes name, daemon status, and ThreadGroup if there is any.
        Specified by:
        newThread in interface ThreadFactory
        Parameters:
        r - A runnable to be executed by new thread instance
        Returns:
        The constructed thread
      • wasThreadCreatedWithThisThreadGroup

        public boolean wasThreadCreatedWithThisThreadGroup​(Thread thread)
        Checks if the thread is member of the thread group
        Parameters:
        thread -
        Returns:
        True If there is a thread group and the given thread is member of the group