Interface FileHeaderPlugin
-
- All Superinterfaces:
FilePlugin<FileHeaderContext,Void>
,Plugin
- All Known Implementing Classes:
AbstractFileHeader
,ConfFileHeader
,JsonFileHeader
,NoneFileHeader
,UnixShellScriptFileHeader
,WindowsShellScriptFileHeader
,XmlFileHeader
public interface FileHeaderPlugin extends FilePlugin<FileHeaderContext,Void>
Plugin that generates a file header comment with info that the file was automatically generated and further info like a timestamp.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description Void
apply(FileContext file, FileHeaderContext context)
Applies the comment file header.default FileHeaderContext
extract(FileContext file)
Extract comment lines from file header.default ImplicitApplyOptions
implicitApply(FileContext file, FileHeaderContext context)
Whether to apply this plugin implicitly.-
Methods inherited from interface io.wcm.devops.conga.generator.spi.FilePlugin
accepts
-
-
-
-
Method Detail
-
implicitApply
default ImplicitApplyOptions implicitApply(FileContext file, FileHeaderContext context)
Whether to apply this plugin implicitly.- Specified by:
implicitApply
in interfaceFilePlugin<FileHeaderContext,Void>
- Parameters:
file
- Context filecontext
- Context objects- Returns:
- Implicit apply option
-
apply
Void apply(FileContext file, FileHeaderContext context)
Applies the comment file header.- Specified by:
apply
in interfaceFilePlugin<FileHeaderContext,Void>
- Parameters:
file
- Context filecontext
- Context objects- Returns:
- nothing
-
extract
default FileHeaderContext extract(FileContext file)
Extract comment lines from file header.- Parameters:
file
- Context file- Returns:
- File header context with comment lines. Returns null if extraction not possible or no comments present.
-
-