ariba.util.core
Class ThreadNameAbbreviation
java.lang.Object
ariba.util.core.ThreadNameAbbreviation
public class ThreadNameAbbreviation
- extends Object
Maintain short names for threads. The short names are
abbreviations used in the log to name threads. For Hashthreads,
the short name is stored in a field of the Hashthread. Names for
other threads are kept in a table indexed by the thread's hash
code. The first time a short name is requested, it is returned as
"=".
This assumes that the hashcodes of different threads are unlikely
to be the same. Perhaps we should also check the name when using
the hashcode.
We should periodically clean out the table.
|
Method Summary |
static String |
getName()
Return the short name of the current thread. |
static String |
getName(Thread thread)
Return the short name of the given thread. |
ThreadNameAbbreviation
public ThreadNameAbbreviation()
getName
public static String getName()
- Return the short name of the current thread.
getName
public static String getName(Thread thread)
- Return the short name of the given thread. For hashthreads,
the short name is stored in a field on the hashthread. Names
for other threads are kept in a table indexed by the thread's
hash code. The first time a short name is requested, it is
returned as "=".
AribaWeb User Interface Development Framework
Copyright © 2000-2009 Ariba, Inc. All Rights Reserved.