PreScriptException.java 605 B

1234567891011121314151617181920212223242526272829
  1. package me.hammerle.snuviscript.exceptions;
  2. public class PreScriptException extends RuntimeException
  3. {
  4. private final int startLine;
  5. private final int endLine;
  6. public PreScriptException(String message, int startLine, int endLine)
  7. {
  8. super(message);
  9. this.endLine = endLine;
  10. this.startLine = startLine;
  11. }
  12. public PreScriptException(String message, int endLine)
  13. {
  14. this(message, -1, endLine);
  15. }
  16. public int getStartLine()
  17. {
  18. return startLine;
  19. }
  20. public int getEndLine()
  21. {
  22. return endLine;
  23. }
  24. }