【全局图】多线程(JUC并发编程)
2024-06-29 09:01:41 0 举报
多线程、JUC编发编程
作者其他创作
大纲/内容
newCachedThreadPool
Thread
同步工具类
Callable
线程池
安全集合类
线程通信
CompletableFuture
Runnable
newSingleThreadExecutor
ThreadPoolExecutor
状态Thread.StateNEW 初始RUNNABLE 运行WAITING 等待TIMED_WAITING 超时等待BLOCKING 阻塞TERMINALED 终止
倒计时闩锁CountDownLatch
创建线程方式
信号量Semaphore
synchonsized + wait( ) + notify( )、notifyAll( )
循环屏障CyclicBarrier
线程方法&状态
Lock
LockSupport
ReentrantLock {lock() + unlock()}Condition {await()+signalAll()}
Execustors. 线程工具类
FutureTask
DiscardOldestPolicy
Thread类start()、run()yield()join()sleep()interrupt()、isInterrupted()Thread.isInterrupted()setPriority()isAlive()
...
CallerRunsPolicy
synchonsized
DiscardPolicy
AbortPolicy
异步编排
线程同步
volatile
ThreadLocal
Atomic
newFixedThreadPool
Object类wait()notify()notifyAll()
0 条评论
下一页