Package br.com.anteros.mqtt.core.util
Class ThreadUtil
- java.lang.Object
-
- br.com.anteros.mqtt.core.util.ThreadUtil
-
public final class ThreadUtil extends Object
mqtt 线程工具类- Author:
- L.cm
-
-
Constructor Summary
Constructors Constructor Description ThreadUtil()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static ThreadPoolExecutorgetGroupExecutor(int groupPoolSize)获取 tio group 线程池static org.tio.utils.thread.pool.SynThreadPoolExecutorgetTioExecutor(int tioPoolSize)获取 getTioExecutor 线程池static booleansleep(long millis)挂起当前线程
-
-
-
Method Detail
-
sleep
public static boolean sleep(long millis)
挂起当前线程- Parameters:
millis- 挂起的毫秒数- Returns:
- 被中断返回false,否则true
-
getGroupExecutor
public static ThreadPoolExecutor getGroupExecutor(int groupPoolSize)
获取 tio group 线程池- Parameters:
groupPoolSize- group 线程大小- Returns:
- ThreadPoolExecutor
-
getTioExecutor
public static org.tio.utils.thread.pool.SynThreadPoolExecutor getTioExecutor(int tioPoolSize)
获取 getTioExecutor 线程池- Parameters:
tioPoolSize- tio 线程池大小- Returns:
- SynThreadPoolExecutor
-
-