Class ProcessApiExamples.CurrentProcessSummary

java.lang.Object
net.jrodolfo.java_evolution.java09.ProcessApiExamples.CurrentProcessSummary
Enclosing class:
ProcessApiExamples

public static class ProcessApiExamples.CurrentProcessSummary extends Object
Small Java 9-style data class for process metadata.
  • Constructor Details

    • CurrentProcessSummary

      public CurrentProcessSummary(long pid, boolean alive, boolean commandAvailable)
      Creates immutable process metadata for tests and examples.
      Parameters:
      pid - the process id
      alive - whether the process is alive
      commandAvailable - whether command metadata is visible
  • Method Details

    • pid

      public long pid()
      Returns:
      the process id
    • alive

      public boolean alive()
      Returns:
      whether the process is currently alive
    • commandAvailable

      public boolean commandAvailable()
      Returns:
      whether process command metadata was available