Class CursorImpl

java.lang.Object
org.asciidoctor.jruby.internal.RubyObjectWrapper
org.asciidoctor.jruby.ast.impl.CursorImpl
All Implemented Interfaces:
Cursor

public class CursorImpl extends RubyObjectWrapper implements Cursor
  • Constructor Details

    • CursorImpl

      public CursorImpl(org.jruby.runtime.builtin.IRubyObject rubyNode)
  • Method Details

    • getLineNumber

      public int getLineNumber()
      Specified by:
      getLineNumber in interface Cursor
      Returns:
      The line number where the owning block begins.
    • getPath

      public String getPath()
      Specified by:
      getPath in interface Cursor
      Returns:
      Source file simple name, or <stdin> value when converting from a String.
    • getDir

      public String getDir()
      Specified by:
      getDir in interface Cursor
      Returns:
      Absolute path to the source file parent directory, or the execution path when converting from a String.
    • getFile

      public String getFile()
      Specified by:
      getFile in interface Cursor
      Returns:
      Absolute path to the source file, or null when converting from a String. This will point to the correct source file, even when it is included from another.
    • toString

      public String toString()
      Overrides:
      toString in class Object