public JmxManager(String host,int beanPort,int registryPort,String serviceName,AuthenticationInfo authInfo){
  this.host=host;
  this.beanPort=beanPort;
  this.registryPort=registryPort;
  this.serviceName=serviceName;
  this.authenticationInfo=authInfo;
  if (authenticationInfo == null) {
    try {
      authenticationInfo=SecurityHelper.loadAuthenticationInformation();
      if (authenticationInfo.isAuthenticationNeeded()) {
        PasswordManager passwordManager=new PasswordManager(authenticationInfo,ClientApplicationType.RMI_JMX);
        String goodPassword=passwordManager.getEncryptedPasswordForUser(authenticationInfo.getUsername());
        authenticationInfo.setPassword(goodPassword);
      }
    }
 catch (    ConfigurationException e) {
      logger.error(MessageFormat.format("Could not get security information. Will use default values: {0}",e));
    }
  }
}

public JmxManager ( String host , int beanPort , int registryPort , String serviceName , AuthenticationInfo authInfo ) { this . host = host ; this . beanPort = beanPort ; this . registryPort = registryPort ; this . serviceName = serviceName ; this . authenticationInfo = authInfo ; if ( authenticationInfo == null ) { try { authenticationInfo = SecurityHelper . loadAuthenticationInformation ( ) ; if ( authenticationInfo . isAuthenticationNeeded ( ) ) { PasswordManager passwordManager = new PasswordManager ( authenticationInfo , ClientApplicationType . RMI_JMX ) ; String goodPassword = passwordManager . getEncryptedPasswordForUser ( authenticationInfo . getUsername ( ) ) ; authenticationInfo . setPassword ( goodPassword ) ; } } catch ( ConfigurationException e ) { logger . error ( MessageFormat . format ( "Could not get security information. Will use default values: {0}" , e ) ) ; } } }
creates an instance to manage a jmx service
