Class JavaDrawingHandler

java.lang.Object
org.oorexx.handlers.jdor.JavaDrawingHandler
All Implemented Interfaces:
RexxCommandHandler, RexxHandler, RexxRedirectingCommandHandler

public class JavaDrawingHandler extends Object implements RexxRedirectingCommandHandler
  • Field Details

    • version

      public static final String version
      See Also:
    • bUseNames4canonical

      public boolean bUseNames4canonical
    • bUseInt4numbers

      public boolean bUseInt4numbers
  • Constructor Details

    • JavaDrawingHandler

      public JavaDrawingHandler()
  • Method Details

    • handleCommand

      public Object handleCommand(Object slot, String address, String command)
      Callback method of this command handler.
      Specified by:
      handleCommand in interface RexxCommandHandler
      Parameters:
      slot - opaque argument (needs to be used if invoking the Handler default methods to interact with the Rexx context)
      address - the environment name this handler works for
      command - the command to process
      Returns:
      any value, which can be retrieved on the Rexx side via the variable RC (result code)
    • getNonBlankWords

      public static String[] getNonBlankWords(String s, ArrayList<int[]> al)
      This will create a word array from the supplied ArrayList returned by getWordBoundaries.
      Parameters:
      s - String
      al - ArrayList returned by getWordBoundaries
      Returns:
      array of words
    • getWordBoundaries

      public static ArrayList<int[]> getWordBoundaries(String s, int maxNumberOfWords)
      Parses the string and returns an ArrayList of int[] denoting the start and the end of each word in the string delimited by ' ' or '\t' the Rexx whitespace characters.
      Parameters:
      s - the string to parse
      maxNumberOfWords - if -1 processes always entire string, otherwise stops after having created maxNumberOfWords items
      Returns:
      an ArrayList of int[] arrays
    • checkBooleanValue

      public static boolean checkBooleanValue(String value)
      Allow "1", ".true", "true" in any case to resolve to a boolean true; allow "0", ".false", "false" in any case to resolve to a boolean false;
      Parameters:
      value - the string that represents a BSF4ooRexx850 boolean value
      Returns:
      true if string represents true, false else
    • getBooleanValue

      public static boolean getBooleanValue(String value)
      Determines the boolean value of a BSF4ooRexx850 boolean string and returns it.
      Parameters:
      value - the string containing a BSF4ooRexx850 boolean rendering
      Returns:
      true if "1", ".TRUE", "TRUE" and false else