Class SourceLocation

  • All Implemented Interfaces:
    FromSourceLocation

    public final class SourceLocation
    extends java.lang.Object
    implements FromSourceLocation
    Represents the source location of a model component.
    • Constructor Detail

      • SourceLocation

        public SourceLocation​(java.lang.String filename,
                              int line,
                              int column)
      • SourceLocation

        public SourceLocation​(java.lang.String filename)
    • Method Detail

      • none

        public static SourceLocation none()
        Creates an empty source location.
        Returns:
        Returns the empty location.
      • getFilename

        public java.lang.String getFilename()
        Returns:
        Returns the source location filename.
      • getLine

        public int getLine()
        Returns:
        Returns the line number from which the component originated.
      • getColumn

        public int getColumn()
        Returns:
        Returns the column from which the component originated.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object