Code example for JsPromptResult

Methods: confirm

0
        			                  String url, 
        			                  String message,
        			                  String defaultValue,
        			                  JsPromptResult result){
	           if(message.trim().equals("get_port")){   
	        	    result.confirm(generateResponseForPort());
	           } else {  
	        	    result.confirm(genrateResponseForClick( message, defaultValue));
	           } 
        	   return true; 
        	} 
        }); 
    } 
     
    private String generateResponseForPort(){
        String response = trimmedServer.getPort()+"";
  	    return response;
    } 
     
    private String genrateResponseForClick(String message, String defaultValue){
    	String response = "";