Class Pos

java.lang.Object
org.smtlib.impl.Pos
All Implemented Interfaces:
IPos

public class Pos extends Object implements IPos
Represents a range of characters in a source - used to indicate the location of errors
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    A Printable that also implements IExpr, additionally holding the sort computed for the expression by the type checker (null if not yet, or never, computed).
    static class 
    An implementation of IPosable, holding an instance of Pos, that can be used as a base class if necessary
    static class 
    A Posable that also implements INode, with toString() delegating to Printer.
    static class 
    An implementation of the ISource interface

    Nested classes/interfaces inherited from interface org.smtlib.IPos

    IPos.IPosable
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    protected int
    One past the last character of the range, beginning from 0
    protected int
    The starting character, beginning from 0
    protected ISource
    The source of text
  • Constructor Summary

    Constructors
    Constructor
    Description
    Pos(int cs, int ce, ISource s)
    Constructor for a Pos object
  • Method Summary

    Modifier and Type
    Method
    Description
    int
    One past the last character of the range, beginning from 0
    int
    The starting character, beginning from 0
    The source of text

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • charStart

      protected int charStart
      The starting character, beginning from 0
    • charEnd

      protected int charEnd
      One past the last character of the range, beginning from 0
    • source

      protected ISource source
      The source of text
  • Constructor Details

    • Pos

      public Pos(int cs, int ce, ISource s)
      Constructor for a Pos object
      Parameters:
      cs - the start position of the character range, 0-based
      ce - one past the end position of the character range, 0- based
      s - the source of text to which the character positions refer
  • Method Details

    • charStart

      public int charStart()
      The starting character, beginning from 0
      Specified by:
      charStart in interface IPos
    • charEnd

      public int charEnd()
      One past the last character of the range, beginning from 0
      Specified by:
      charEnd in interface IPos
    • source

      public ISource source()
      The source of text
      Specified by:
      source in interface IPos