Class SysDeEdit

java.lang.Object
svm.env.SysDeEdit

public abstract class SysDeEdit extends Object

De-Editing Routines

Link to GitHub: Source File.

Author:
Simula Standard, S-Port: The Environment Interface, Øystein Myhre Andersen
  • Constructor Details

    • SysDeEdit

      public SysDeEdit()
      Default Constructor
  • Method Details

    • getIntegerItem

      private static String getIntegerItem(String T)

      Scan the input text for an integer item.

      INTEGER-ITEM = SIGN-PART DIGITS
         SIGN-PART = BLANKS [ SIGN ] BLANKS
            SIGN = + | -
         DIGITS = DIGIT { DIGIT }
            DIGIT = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
      
      Parameters:
      T - string to be decoded
      Returns:
      the INTEGER ITEM string
    • getint

      public static void getint()

      Procedure getint.

      Visible sysroutine("GETINT") GETINT;
      import infix (string) item; export integer res end;
      
      Runtime Stack
         ..., item'addr, item'nchr →
         ..., res
      

      The argument item String is popped of the Runtime stack.
      An INTEGER ITEM is located in that String.
      Finally: That ITEM is decoded and pushed onto the Runtime stack.

      INTEGER-ITEM = SIGN-PART DIGITS
         SIGN-PART = BLANKS [ SIGN ] BLANKS
            SIGN = + | -
         DIGITS = DIGIT { DIGIT }
            DIGIT = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
      
    • getRealItem

      private static String getRealItem(String T)

      Scan the input text for a real item.

      REAL-ITEM = DECIMAL-ITEM [ EXPONENT ] | SIGN-PART EXPONENT
         DECIMAL-ITEM = INTEGER-ITEM [ FRACTION ] | SIGN-PART FRACTION
            INTEGER-ITEM = SIGN-PART DIGITS
            FRACTION = DECIMAL-MARK DIGITS
            SIGN-PART = BLANKS [ SIGN ] BLANKS
         EXPONENT = LOWTEN-CHARACTER INTEGER-ITEM
               SIGN = + | -
               DIGITS = DIGIT { DIGIT }
               DIGIT = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
               LOWTEN-CHARACTER = & | ...
               DECIMAL-MARK = . | ,
               BLANKS = { BLANK | TAB }
      
      Parameters:
      T - string to be decoded
      Returns:
      the REAL ITEM string
    • getreal

      public static void getreal()

      Procedure getreal.

      Visible sysroutine("GTREAL") GTREAL;
      import infix (string) item; export long real res end;
      
      Runtime Stack
         ..., item'addr, item'nchr →
         ..., res
      

      The argument item String is popped of the Runtime stack.
      An REAL ITEM is located in that String.
      Finally: That ITEM is decoded and pushed onto the Runtime stack.

      REAL-ITEM = DECIMAL-ITEM [ EXPONENT ] | SIGN-PART EXPONENT
         DECIMAL-ITEM = INTEGER-ITEM [ FRACTION ] | SIGN-PART FRACTION
            INTEGER-ITEM = SIGN-PART DIGITS
            FRACTION = DECIMAL-MARK DIGITS
            SIGN-PART = BLANKS [ SIGN ] BLANKS
         EXPONENT = LOWTEN-CHARACTER INTEGER-ITEM
               SIGN = + | -
               DIGITS = DIGIT { DIGIT }
               DIGIT = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
               LOWTEN-CHARACTER = & | ...
               DECIMAL-MARK = . | ,
               BLANKS = { BLANK | TAB }
      
    • getFracItem

      private static String getFracItem(String T)

      Scan the input text for a fraction item.

      GROUPED-ITEM = SIGN-PART GROUPS [ DECIMAL-MARK GROUPS ]
                   | SIGN-PART DECIMAL-MARK GROUPS
      	SIGN-PART = BLANKS [ SIGN ] BLANKS
      		SIGN = + | -
      	GROUPS = DIGITS { BLANK DIGITS } DIGITS = DIGIT { DIGIT }
      		DIGIT = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
      
      Parameters:
      T - string to be decoded
      Returns:
      the GROUPED ITEM string
    • getfrac

      public static void getfrac()

      Procedure getfrac.

      Visible sysroutine("GTFRAC") GTFRAC;
      import infix (string) item; export integer res end;
      
      Runtime Stack
         ..., item'addr, item'nchr →
         ..., res
      

      The argument item String is popped of the Runtime stack.
      A GROUPED ITEM is located in that String.
      Finally: That ITEM is decoded and pushed onto the Runtime stack.

      The digits of a GROUPED ITEM may be interspersed with BLANKS and a single DECIMAL MARK which are ignored.

      GROUPED-ITEM = SIGN-PART GROUPS [ DECIMAL-MARK GROUPS ]
                   | SIGN-PART DECIMAL-MARK GROUPS
      	SIGN-PART = BLANKS [ SIGN ] BLANKS
      		SIGN = + | -
      	GROUPS = DIGITS { BLANK DIGITS } DIGITS = DIGIT { DIGIT }
      		DIGIT = 0 | 1 | 2 | 3 | 4 | 5 | 6 | 7 | 8 | 9
      

      The procedure locates a GROUPED ITEM. The function value is equal to the resulting integer. The digits of a GROUPED ITEM may be interspersed with BLANKS and a single DECIMAL MARK which are ignored by the procedure.