Package org.apache.camel.impl.engine
Class DefaultNodeIdFactory
- java.lang.Object
-
- org.apache.camel.impl.engine.DefaultNodeIdFactory
-
- All Implemented Interfaces:
org.apache.camel.spi.NodeIdFactory
public class DefaultNodeIdFactory extends Object implements org.apache.camel.spi.NodeIdFactory
Default id factory.
-
-
Field Summary
Fields Modifier and Type Field Description protected static Map<String,AtomicInteger>nodeCounters
-
Constructor Summary
Constructors Constructor Description DefaultNodeIdFactory()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description StringcreateId(org.apache.camel.NamedNode definition)protected static AtomicIntegergetNodeCounter(String key)Returns the counter for the given node key, lazily creating one if necessaryprotected static voidresetAllCounters()Helper method for test purposes that allows tests to start clean (made protected to ensure that it is not called accidentally)
-
-
-
Field Detail
-
nodeCounters
protected static Map<String,AtomicInteger> nodeCounters
-
-
Method Detail
-
createId
public String createId(org.apache.camel.NamedNode definition)
- Specified by:
createIdin interfaceorg.apache.camel.spi.NodeIdFactory
-
getNodeCounter
protected static AtomicInteger getNodeCounter(String key)
Returns the counter for the given node key, lazily creating one if necessary
-
resetAllCounters
protected static void resetAllCounters()
Helper method for test purposes that allows tests to start clean (made protected to ensure that it is not called accidentally)
-
-