Class CommentFormatter

java.lang.Object
org.aoju.bus.setting.format.AbstractFormatter<IniComment>
org.aoju.bus.setting.format.CommentFormatter
All Implemented Interfaces:
ElementFormatter<IniComment>

public class CommentFormatter extends AbstractFormatter<IniComment>
将字符串值格式设置为IniComment
Since:
Java 17+
Author:
Kimi Liu
  • Constructor Details

    • CommentFormatter

      public CommentFormatter(char startChar)
    • CommentFormatter

      public CommentFormatter()
  • Method Details

    • format

      public IniComment format(String value, int line)
      Description copied from interface: ElementFormatter
      this method will not check value, so you should ElementFormatter.check(String) first. However, not checking will not necessarily report an error, but may result in non-compliance.
      Parameters:
      value - a String value
      line - line number
      Returns:
      ElementFormatter, can not be null.
    • check

      public boolean check(String value)
      Description copied from interface: ElementFormatter
      check this value.
      Parameters:
      value - value
      Returns:
      true if can.