國文屋

位置:首頁 > 造句 > 

“ThreadLocal”造句,怎麼用ThreadLocal造句

造句2.49W

更慢一點兒的數據結構是HashMap,然後是Threadlocal(這基本上是一個以當前線程作為鍵的特殊散列表)。

相反地,人們通過給Thread添加一個實例變量(該變量用於保存當前線程的從線程局部變量到它的值的映*的HashMap)來修改thread類以支持ThreadLocal

ThreadLocal造句

不用説,ThreadLocal的*能是相當差的。

The next-fastest data structure is HashMap, followed by ThreadLocal (essentially, a specialized hash table in which the current thread is the key).

With these new improvements, ThreadLocal should be faster than other techniques such as pooling.

Instead, the thread class was modified to support ThreadLocal by adding an instance variable to thread that holds a HashMap mapping thread-local variables to their values for the current thread.

有了這些提高,ThreadLocal應該比其它技術,如用池,更快。

標籤:造句 ThreadLocal