Previous Table of Contents Next


9.11.2 LiteralInteger


   A literal integer is a specification of an integer value.

   Description

   A literal integer contains an Integer-valued attribute.

   Generalizations

   • “LiteralSpecification? on page 61

   Attributes

   • value: Integer The specified Integer value.

   Associations

   No additional associations

   Constraints

   No additional constraints

   Additional Operations

   [1] The query isComputable() is redefined to be true.

   LiteralInteger::isComputable(): Boolean;isComputable = true

   [2] The query integerValue() gives the value.

   LiteralInteger::integerValue() : [Integer];integerValue = value

   Semantics

   A LiteralInteger specifies a constant Integer value.

   Notation

   A LiteralInteger is typically shown as a sequence of digits.