Class StringConstant

  • All Implemented Interfaces:
    Value

    public final class StringConstant
    extends Constant
    Represents a string constant.
    • Constructor Detail

      • StringConstant

        public StringConstant​(String value)
        Creates a string constant with the given value.
        Parameters:
        value - the string value
    • Method Detail

      • getType

        public IRType getType()
        Description copied from interface: Value
        Gets the IR type of this value.
        Returns:
        the IR type
      • getValue

        public String getValue()
        Description copied from class: Constant
        Gets the value of this constant.
        Specified by:
        getValue in class Constant
        Returns:
        the constant value
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object