Class CommentLine

java.lang.Object
org.snakeyaml.engine.v2.comments.CommentLine

public class CommentLine extends Object
A comment line. Maybe a block comment, blank line, or inline comment.
  • Field Details

  • Constructor Details

    • CommentLine

      public CommentLine(CommentEvent event)
      Create
      Parameters:
      event - - the source
    • CommentLine

      public CommentLine(Optional<Mark> startMark, Optional<Mark> endMark, String value, CommentType commentType)
      Create
      Parameters:
      startMark - - start
      endMark - - end
      value - - the comment
      commentType - - the type
  • Method Details

    • getEndMark

      public Optional<Mark> getEndMark()
      getter
      Returns:
      end position
    • getStartMark

      public Optional<Mark> getStartMark()
      getter
      Returns:
      start position
    • getCommentType

      public CommentType getCommentType()
      getter
      Returns:
      type of it
    • getValue

      public String getValue()
      Value of this comment.
      Returns:
      comment's value.
    • toString

      public String toString()
      Overrides:
      toString in class Object