Promise<Object> (@NotNull PlaybackContext context) { final String s = getText().substring(PREFIX.length()).trim(); try { final int delay = Integer.parseInt(s); context.getRobot().delay(delay); } catch (NumberFormatException e) { dumpError(context, "Invalid delay value: " + s); return Promises.rejectedPromise(e); } return Promises.resolvedPromise(); }