Package ninja.leaping.configurate.loader
Interface CommentHandler
-
- All Known Implementing Classes:
CommentHandlers
public interface CommentHandler
Interface specifying methods for handling abstract comments
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description @NonNull Optional<String>
extractHeader(@NonNull BufferedReader reader)
Defines the handlers behaviour for reading comments.@NonNull Collection<String>
toComment(@NonNull Collection<String> lines)
Converts the given lines into a comment
-
-
-
Method Detail
-
extractHeader
@NonNull Optional<String> extractHeader(@NonNull BufferedReader reader) throws IOException
Defines the handlers behaviour for reading comments.- Parameters:
reader
- The reader- Returns:
- The comment
- Throws:
IOException
- If any IO error occurs in the process
-
toComment
@NonNull Collection<String> toComment(@NonNull Collection<String> lines)
Converts the given lines into a comment- Parameters:
lines
- The lines to make a comment- Returns:
- The transformed lines
-
-