private T setInitialValue() { T value = initialValue(); Thread t = Thread.currentThread(); ThreadLocalMap map = getMap(t); if (map != null) map.set(this, value); else createMap(t, value); return value; }
private void put0(String key, Object o) { if(java1 || tlm == null) { return; } else { Hashtable ht = (Hashtable) ((ThreadLocalMap)tlm).get(); if(ht == null) { ht = new Hashtable(HT_SIZE); ((ThreadLocalMap)tlm).set(ht); } ht.put(key, o); } }
private void put0(String key, Object o) { if (java1 || tlm == null) { return; } else { Hashtable ht = (Hashtable) ((ThreadLocalMap) tlm).get(); if (ht == null) { ht = new Hashtable(HT_SIZE); ((ThreadLocalMap) tlm).set(ht); } ht.put(key, o); } }
public void set(T value) { Thread t = Thread.currentThread(); ThreadLocalMap map = getMap(t); if (map != null) map.set(this, value); else createMap(t, value); }
private T setInitialValue() { T value = initialValue(); Thread t = Thread.currentThread(); ThreadLocalMap map = getMap(t); if (map != null) map.set(this, value); else createMap(t, value); return value; }
public void set(T value) { Thread t = Thread.currentThread(); ThreadLocalMap map = getMap(t); if (map != null) map.set(this, value); else createMap(t, value); }
public void set(T value) { ThreadLocalMap map = getMap(Thread.currentThread()); map.set(this, value); }
public class ThreadLocal<T> { ......... ......... /** * Sets the current thread's copy of this thread-local variable * to the specified value. Most subclasses will have no need to * override this method, relying solely on the {@link #initialValue} * method to set the values of thread-locals. * * @param value the value to be stored in the current thread's copy of * this thread-local. */ public void set(T value) { Thread t = Thread.currentThread(); ThreadLocalMap map = getMap(t); if (map != null) map.set(this, value); else createMap(t, value); } }
private void put0(String key, Object o) { if(java1 || tlm == null) { return; } else { Hashtable ht = (Hashtable) ((ThreadLocalMap)tlm).get(); if(ht == null) { ht = new Hashtable(HT_SIZE); ((ThreadLocalMap)tlm).set(ht); } ht.put(key, o); } }
private void put0(String key, Object o) { if(java1 || tlm == null) { return; } else { Hashtable ht = (Hashtable) ((ThreadLocalMap)tlm).get(); if(ht == null) { ht = new Hashtable(HT_SIZE); ((ThreadLocalMap)tlm).set(ht); } ht.put(key, o); } }