Code example for MalformedObjectNameException

Methods: printStackTrace

0
		J4pSearchResponse searchResponse = null;
		try { 
			J4pSearchRequest searchRequest = new J4pSearchRequest(request);
			searchResponse = j4pClient.execute(searchRequest);
		} catch (MalformedObjectNameException e) {
			e.printStackTrace();
		} catch (J4pException e) {
			e.printStackTrace();			
		} 
		return searchResponse == null ? null : searchResponse.getMBeanNames();
	} 
 
	//<base url>/exec/<mbean name>/<operation name>/<arg1>/<arg2>/.... 
	public String execOperation(String mbeanName, String opName, Object... args) throws MalformedObjectNameException, J4pException {
		J4pExecRequest exec;
		String result = null;
		exec = new J4pExecRequest(mbeanName, opName, args);
		J4pExecResponse execResp = j4pClient.execute(exec);
		if (execResp.getValue() != null) {
			result = execResp.getValue().toString();