Class ImageToken


  • public class ImageToken
    extends Token
    Represents an image filename token in the Picasso language
    • Constructor Detail

      • ImageToken

        public ImageToken​(String value)
        Constructs a token representing an image filename
        Parameters:
        value - The filename (without the quotes)
    • Method Detail

      • getValue

        public String getValue()
        Gets the filename value of this image token
        Returns:
        The filename (without quotes)
      • toString

        public String toString()
        Returns a string representation of this image token
        Overrides:
        toString in class Token
        Returns:
        A string representation in the format "Image Token: filename"
      • equals

        public boolean equals​(Object obj)
        Checks if this token equals another object
        Overrides:
        equals in class Object
        Parameters:
        obj - the object to compare with
        Returns:
        true if the tokens are equal, false otherwise
      • isConstant

        public boolean isConstant()
        Checks if this token is a constant
        Specified by:
        isConstant in class Token
        Returns:
        false, as ImageToken is not a constant
      • isFunction

        public boolean isFunction()
        Checks if this token is a function
        Specified by:
        isFunction in class Token
        Returns:
        false, as ImageToken is not a function