Package ru.vyarus.guicey.spa
Class SpaBundle.Builder
java.lang.Object
ru.vyarus.guicey.spa.SpaBundle.Builder
- Enclosing class:
- SpaBundle
Spa bundle builder.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()preventRedirectRegex(String regex) Redirect filter will prevent redirection when accept header is not compatible with text/html.
-
Constructor Details
-
Builder
-
-
Method Details
-
indexPage
- Parameters:
name- index file name (by default "index.html")- Returns:
- builder instance
-
preventRedirectRegex
Redirect filter will prevent redirection when accept header is not compatible with text/html. As this may not be enough, default regexSpaBundle.DEFAULT_PATTERNis used to prevent redirection in some cases. By default it's all common web files (html, css, js) with possible version markers (e.g. ?ver=1214324).NOTE: regex is applied with "find", so use ^ or $ to apply boundaries.
- Parameters:
regex- regular expression to prevent redirection to root (prevent when regex matched)- Returns:
- builder instance
-
build
- Returns:
- configured dropwizard bundle instance
-