Class Program

All Implemented Interfaces:
Runnable
Direct Known Subclasses:
ApiToolCommand, Client, VersionProgram

public abstract class Program extends ProgramComponent implements Runnable
  • Field Details

  • Constructor Details

    • Program

      protected Program(String... arguments)
  • Method Details

    • runProgram

      protected abstract void runProgram() throws ProgramException
      Throws:
      ProgramException
    • isClient

      public final boolean isClient()
    • getProgramName

      public final String getProgramName()
    • setProgramName

      public final Program setProgramName(String name)
    • writeProgramMessage

      protected final void writeProgramMessage(String format, Object... arguments)
    • addOption

      protected final void addOption(String name, Program.Option.Handler handler, String... operands)
    • addRequiredParameters

      protected final void addRequiredParameters(String... parameters)
    • addOptionalParameters

      protected final void addOptionalParameters(String... parameters)
    • addRepeatingParameter

      protected final void addRepeatingParameter(String parameter)
    • getPurpose

      public String getPurpose()
    • extendUsageSummary

      protected void extendUsageSummary(StringBuilder usage)
    • getUsageSummary

      public final String getUsageSummary()
    • processParameters

      protected void processParameters(String[] parameters) throws SyntaxException
      Throws:
      SyntaxException
    • onProgramException

      protected void onProgramException(ProgramException exception)
    • run

      public final void run()
      Specified by:
      run in interface Runnable