String (String startMarker, String endMarker) { final int start = outputBuffer.indexOf(startMarker); final int end = outputBuffer.indexOf(endMarker); if (start > end) { throw new AssertionError("Malformed Groovyc output: " + outputBuffer); } String text = outputBuffer.substring(start + startMarker.length(), end); outputBuffer.delete(start, end + endMarker.length()); return text.trim(); }