Interface Editor
- All Known Implementing Classes:
DefaultEditor, FingerprintingEditor
public interface Editor
API for simple edition of text files like docker files.
-
Method Summary
Modifier and TypeMethodDescriptionvoidRestricts edition to lines after the given line.voidRestricts edition to lines before the given line.voidInserts the provided lines after the current lower bound.voidReplaces lines matching the current lower and upper bounds with the provided replacement.voidReplaces lines matching the current lower and upper bounds with the replacement, if they match the line pattern.voidreplaceRegex(String regex, String replacement) Replaces strings matching the current lower and upper bounds with the replacement, if they match the line pattern.
-
Method Details
-
after
-
before
-
replace
Replaces lines matching the current lower and upper bounds with the provided replacement.- Parameters:
replacement- the replacement
-
replace
-
replaceRegex
-
insert
Inserts the provided lines after the current lower bound.- Parameters:
lines- the lines to be inserted
-