public static ElkTimer getNamedTimer ( String timerName , int todoFlags , long threadId ) { ElkTimer key = new ElkTimer ( timerName , todoFlags , threadId ) ; ElkTimer previous = registeredTimers . putIfAbsent ( key , key ) ; if ( previous != null ) { return previous ; } // else return key ; }
Get a timer of the given string name for the given thread . If no such timer exists yet then it will be newly created .