Package io.cucumber.htmlformatter
Class MessagesToHtmlWriter.Builder
- java.lang.Object
-
- io.cucumber.htmlformatter.MessagesToHtmlWriter.Builder
-
- Enclosing class:
- MessagesToHtmlWriter
public static final class MessagesToHtmlWriter.Builder extends Object
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description MessagesToHtmlWriterbuild(OutputStream out)Create an instance of the messages to html writer.MessagesToHtmlWriter.Buildercss(Supplier<InputStream> css)Sets default css for the report.MessagesToHtmlWriter.BuildercustomCss(Supplier<InputStream> customCss)Sets custom css for the report.MessagesToHtmlWriter.BuildercustomScript(Supplier<InputStream> customScript)Sets custom script for the report.MessagesToHtmlWriter.Buildericon(String icon)Sets a custom icon for the report, default value the cucumber logo.MessagesToHtmlWriter.Buildericon(Supplier<InputStream> icon)Sets a custom icon for the report, default value the cucumber logo.MessagesToHtmlWriter.Builderscript(Supplier<InputStream> script)Replaces default script for the report.MessagesToHtmlWriter.Buildertitle(String title)Sets a custom title for the report, default value "Cucumber".
-
-
-
Method Detail
-
title
public MessagesToHtmlWriter.Builder title(String title)
Sets a custom title for the report, default value "Cucumber".- Parameters:
title- the custom title.- Returns:
- this builder
-
icon
public MessagesToHtmlWriter.Builder icon(Supplier<InputStream> icon)
Sets a custom icon for the report, default value the cucumber logo.The
iconis any validhrefvalue.- Parameters:
icon- a supplier for the custom icon.- Returns:
- this builder
-
icon
public MessagesToHtmlWriter.Builder icon(String icon)
Sets a custom icon for the report, default value the cucumber logo.The
iconis any validhrefvalue.- Parameters:
icon- the custom icon.- Returns:
- this builder
-
css
public MessagesToHtmlWriter.Builder css(Supplier<InputStream> css)
Sets default css for the report.The default script styles the cucumber report. Unless you are building your own html report you should use
customCss(Supplier)instead.- Parameters:
css- a supplier for the default css.- Returns:
- this builder
-
customCss
public MessagesToHtmlWriter.Builder customCss(Supplier<InputStream> customCss)
Sets custom css for the report.The custom css is applied after the default css.
- Parameters:
customCss- a supplier for the custom css.- Returns:
- this builder
- See Also:
- Cucumber - React Components - Styling
-
script
public MessagesToHtmlWriter.Builder script(Supplier<InputStream> script)
Replaces default script for the report.The default script renders the cucumber messages into a report. Unless you are building yourMessagesToHtmlWriter own html report you should use
customScript(Supplier)instead.- Parameters:
script- a supplier for the default script.- Returns:
- this builder
-
customScript
public MessagesToHtmlWriter.Builder customScript(Supplier<InputStream> customScript)
Sets custom script for the report.The custom script is applied after the default script.
- Parameters:
customScript- a supplier for the custom script.- Returns:
- this builder
-
build
public MessagesToHtmlWriter build(OutputStream out)
Create an instance of the messages to html writer.- Parameters:
out- the output stream to write to- Returns:
- a new instance of the messages to html writer.
-
-