Class RepetitionValue

java.lang.Object
svm.value.Value
svm.value.RepetitionValue

public class RepetitionValue extends Value

RepetitionValue.

record_value
 repetition_value
	::= <boolean_value>+
	::= <character_value>+ | text_value
	::= <integer_value>+ | <size_value>+
	::= <real_value>+ | <longreal_value>+
	::= <attribute_address>+ | <object_address>+
	::= <general_address>+ | <program_address>+
	::= <routine_address>+ | <record_value>+

text_value      ::= text long_string
boolean_value   ::= true | false 
character_value ::= c-char byte
integer_value   ::= c-int integer_literal:string
real_value      ::= c-real real_literal:string 
longreal_value  ::= c-lreal real_literal:string
size_value      ::= c-size type | nosize

attribute_address
	::= < c-dot attribute:tag >* c-aaddr attribute:tag
	::= anone

object_address
	::= c-oaddr global_or_const:tag
	::= onone

general_address
	::= < c-dot attr:tag >* c-gaddr global_or_const:tag
	::= gnone

program_address ::= c-paddr label:tag | nowhere
routine_address ::= c-raddr body:tag | nobody

record_value
	::= c-record structured_type
		<attribute_value>+ endrecord

Link to GitHub: Source File.

Author:
S-Port: Definition of S-code, Øystein Myhre Andersen
  • Field Details

  • Constructor Details

    • RepetitionValue

      public RepetitionValue()
      Default Constructor
    • RepetitionValue

      private RepetitionValue(Type type, Vector<Value> values)
      Construct a new RepetitionValue with the given parameters.
      Parameters:
      type - the value type
      values - the values
  • Method Details

    • ofValue

      public static RepetitionValue ofValue(Value value)
      Create a new RepetitionValue of the given value.
      Parameters:
      value - the value
      Returns:
      a new RepetitionValue with the value
    • ofScode

      public static RepetitionValue ofScode()
      Scans the remaining S-Code belonging to this RepetitionValue. Then construct a new RepetitionValue instance.
      Returns:
      that RepetitionValue instance.
    • emit

      public void emit(DataSegment dseg)
      Description copied from class: Value
      Add this value to the given DataSegment
      Overrides:
      emit in class Value
      Parameters:
      dseg - the DataSegment
    • print

      public void print(String indent)
      Description copied from class: Value
      Utility print method.
      Overrides:
      print in class Value
      Parameters:
      indent - number of spaces leading the lines
    • toString

      public String toString()
      Overrides:
      toString in class Object