Class IsJvmLauncherLine

java.lang.Object
org.ek9lang.compiler.common.IsJvmLauncherLine
All Implemented Interfaces:
Predicate<String>

public final class IsJvmLauncherLine extends Object implements Predicate<String>
THE lines the JVM launcher writes on stderr before main runs - Picked up JAVA_TOOL_OPTIONS: ... (and _JAVA_OPTIONS, NOTE: Picked up JDK_JAVA_OPTIONS) whenever such a variable is set. No flag turns them off and no EK9 code can write ahead of them, so a reader of a child JVM's stderr skips them while they LEAD it: they are the JVM's, never the run's (Steve's environment sets JAVA_TOOL_OPTIONS=-Dfile.encoding=UTF-8; 2026-10-24). The variable itself is never stripped from a child's environment - it is the user's.

Readers: Ek9FailureMarker (the marker is the first line AFTER them, FirstLineFailureCode) and the debugger's output pump (org.ek9lang.debug.JdiSession, as quiet=y keeps JDWP's own banner out of the program's output). Only a leading line counts: the same text later was printed by the program.

No statics (Steve, 2026-10-28; was JvmLauncherLines): hold an instance of this, or of WithoutJvmLauncherLines for a capture with its leading launcher lines dropped.

  • Constructor Details

    • IsJvmLauncherLine

      public IsJvmLauncherLine()
  • Method Details

    • test

      public boolean test(String line)
      True when line (surrounding whitespace aside) is one the JVM launcher writes for an options variable.
      Specified by:
      test in interface Predicate<String>