public JSONObject toJSONObject ( MBeanServerExecutor pServerManager ) { JSONObject ret = new JSONObject ( ) ; addNullSafe ( ret , "vendor" , vendor ) ; addNullSafe ( ret , "product" , product ) ; addNullSafe ( ret , "version" , version ) ; Map < String , String > extra = getExtraInfo ( pServerManager ) ; if ( extra != null ) { JSONObject jsonExtra = new JSONObject ( ) ; for ( Map . Entry < String , String > entry : extra . entrySet ( ) ) { jsonExtra . put ( entry . getKey ( ) , entry . getValue ( ) ) ; } ret . put ( "extraInfo" , jsonExtra ) ; } return ret ; }
Return this info as an JSONObject