Module Simula

Class RTS_RTObject.RTS_REF_ARRAY<T>

java.lang.Object
simula.runtime.RTS_ARRAY
simula.runtime.RTS_RTObject.RTS_REF_ARRAY<T>
Type Parameters:
T - the actual array type
Enclosing class:
RTS_RTObject

public final class RTS_RTObject.RTS_REF_ARRAY<T> extends RTS_ARRAY
This class represent a Simula ref(T) array.
  • Field Details

    • ELTS

      private final RTS_RTObject[] ELTS
      The elements in this RTS_REF_ARRAY
  • Constructor Details

    • RTS_REF_ARRAY

      public RTS_REF_ARRAY(RTS_RTObject.RTS_BOUNDS... BOUNDS)
      Create a ref() array with the given bounds.
      Parameters:
      BOUNDS - the array bounds
  • Method Details

    • putELEMENT

      public T putELEMENT(int ix, T val)
      This method will put a object reference into ELTS[ix]
      Parameters:
      ix - the index of ELTS
      val - the value to put
      Returns:
      the value stored
    • getELEMENT

      public T getELEMENT(int... x)
      This method will return a value from ELTS[x...]
      Parameters:
      x - the indexes of ELTS
      Returns:
      the value loaded
    • COPY

      public RTS_RTObject.RTS_REF_ARRAY<T> COPY()
      Description copied from class: RTS_ARRAY
      Abstract method redefined for all subclass <type>_ARRAY
      Specified by:
      COPY in class RTS_ARRAY
      Returns:
      a copy of this _ARRAY