protected Index getJandexIndex ( ) { String methodName = "getJandexIndex" ; boolean doLog = tc . isDebugEnabled ( ) ; boolean doJandexLog = JandexLogger . doLog ( ) ; boolean useJandex = getUseJandex ( ) ; if ( ! useJandex ) { // Figuring out if there is a Jandex index is mildly expensive, // and is to be avoided when logging is disabled. if ( doLog || doJandexLog ) { boolean haveJandex = basicHasJandexIndex ( ) ; String msg ; if ( haveJandex ) { msg = MessageFormat . format ( "[ {0} ] Jandex disabled; Jandex index [ {1} ] found" , getHashText ( ) , getJandexIndexPath ( ) ) ; } else { msg = MessageFormat . format ( "[ {0} ] Jandex disabled; Jandex index [ {1} ] not found" , getHashText ( ) , getJandexIndexPath ( ) ) ; } if ( doLog ) { Tr . debug ( tc , msg ) ; } if ( doJandexLog ) { JandexLogger . log ( CLASS_NAME , methodName , msg ) ; } } return null ; } else { Index jandexIndex = basicGetJandexIndex ( ) ; if ( doLog || doJandexLog ) { String msg ; if ( jandexIndex != null ) { msg = MessageFormat . format ( "[ {0} ] Jandex enabled; Jandex index [ {1} ] found" , getHashText ( ) , getJandexIndexPath ( ) ) ; } else { msg = MessageFormat . format ( "[ {0} ] Jandex enabled; Jandex index [ {1} ] not found" , getHashText ( ) , getJandexIndexPath ( ) ) ; } if ( doLog ) { Tr . debug ( tc , msg ) ; } if ( doJandexLog ) { JandexLogger . log ( CLASS_NAME , methodName , msg ) ; } } return jandexIndex ; } }
Attempt to read the Jandex index .