final boolean registerListener ( NodeTypes . Listener listener ) { return listener != null ? this . listeners . addIfAbsent ( listener ) : false ; }
Add a listener that will be notified when the NodeTypes changes . Listeners will be called in a single thread and should do almost no work .