Class BitcoinClientThreadFactory
java.lang.Object
org.consensusj.bitcoin.jsonrpc.internal.BitcoinClientThreadFactory
- All Implemented Interfaces:
ThreadFactory
A
ThreadFactory for the BitcoinClient. It is based upon bitcoinj's
ContextPropagatingThreadFactory but differs in a few ways:
- It takes a
Contextin the constructor rather than propagating the Context from the caller. We want all threads in the pool to have the same context as the associatedBitcoinClientand (more importantly) the connected server. - Does not use bitcoinj's
Threading.uncaughtExceptionHandlermechanism. (For now, it just logs the uncaught exceptions.) - Has no direct dependencies on Guava, though it does depend on bitcoinj.
-
Constructor Summary
ConstructorsConstructorDescriptionBitcoinClientThreadFactory(org.bitcoinj.core.Context context, String name) BitcoinClientThreadFactory(org.bitcoinj.core.Context context, String name, int priority) -
Method Summary
-
Constructor Details
-
BitcoinClientThreadFactory
-
BitcoinClientThreadFactory
-
-
Method Details
-
newThread
- Specified by:
newThreadin interfaceThreadFactory
-