WebResourcesConfig

class WebResourcesConfig

Web resources serve configuration

Constructors

<init>

WebResourcesConfig()

Web resources serve configuration

Properties

excludes

val excludes: MutableList<(String) -> Boolean>

Path predicates to be excluded. By default WEB-INF directory is excluded. A path provided to a predicate is always slash-separated (/).

includes

val includes: MutableList<(String) -> Boolean>

Path predicates to be included. All files will be served if no include rules specified. A path provided to a predicate is always slash-separated (/).

mimeResolve

var mimeResolve: (String) -> ContentType

Content-type resolution, uses defaultForFileExtension by default

Functions

exclude

fun exclude(predicate: (path: String) -> Boolean): Unit

Add predicate exclusion rule to excludes

include

fun include(predicate: (path: String) -> Boolean): Unit

Add predicate to includes