JAL-3026-JAL-3063 transpiler and runtime update
[jalview.git] / src / jalview / util / dialogrunner / Response.java
index 15df8f8..f168e20 100644 (file)
@@ -108,8 +108,17 @@ public class Response
     case 1:
       return "DialogRunner str: '" + stringresp + "'";
     case 2:
-      return "DialogRunner obj: " + objresp.toString();
+      return "DialogRunner obj: " + String.valueOf(objresp);
     }
     return "Unconfigured response.";
   }
+
+  /**
+   * null response - triggers the default response
+   * @return
+   */
+  public boolean isNull()
+  {
+    return (type==2 && objresp==null) || (type==1 && (stringresp==null || stringresp.equals("")));
+  }
 }
\ No newline at end of file