Exemplo n.º 1
0
 private boolean send(String cmd, StringBuilder response) {
   try {
     response.append(m_gtp.send(cmd));
     return true;
   } catch (GtpError error) {
     response.append(error.getMessage());
     return false;
   }
 }
Exemplo n.º 2
0
 private void listCommands() {
   try {
     m_gtp.querySupportedCommands();
   } catch (GtpError error) {
     System.out.println(error.getMessage());
     return;
   }
   ArrayList<String> commands = m_gtp.getSupportedCommands();
   for (int i = 0; i < commands.size(); ++i) System.out.println(commands.get(i));
 }