public static class ClasspathFilesHandler.ClasspathFilesHandlerBuilder extends Object
ClasspathFilesHandler
builder.Modifier and Type | Method and Description |
---|---|
ClasspathFilesHandler |
build()
Builds and returns the
ClasspathFilesHandler instance. |
ClasspathFilesHandler.ClasspathFilesHandlerBuilder |
expireTimeSeconds(int expireTimeSeconds)
Returns the instance of
ClasspathFilesHandler.ClasspathFilesHandlerBuilder configured with the given duration as the
expiration time for static resources. |
ClasspathFilesHandler.ClasspathFilesHandlerBuilder |
guessMimeType()
activate content type guessing.
|
ClasspathFilesHandler.ClasspathFilesHandlerBuilder |
rootDirectory(String root)
Returns the instance of
ClasspathFilesHandler.ClasspathFilesHandlerBuilder configured with the given path as the root
directory for resources to serve. |
ClasspathFilesHandler.ClasspathFilesHandlerBuilder |
welcomeFile(String welcome)
Returns the instance of
ClasspathFilesHandler.ClasspathFilesHandlerBuilder configured with the given file name as the
index. |
public ClasspathFilesHandler build()
ClasspathFilesHandler
instance.ClasspathFilesHandler
instance.public ClasspathFilesHandler.ClasspathFilesHandlerBuilder expireTimeSeconds(int expireTimeSeconds)
ClasspathFilesHandler.ClasspathFilesHandlerBuilder
configured with the given duration as the
expiration time for static resources.expireTimeSeconds
- Sets the expire-time in seconds for static resources.ClasspathFilesHandler.ClasspathFilesHandlerBuilder
to continue configuring the
ClasspathFilesHandler
instance.public ClasspathFilesHandler.ClasspathFilesHandlerBuilder guessMimeType()
Mime
. Note this may impact the performance.ClasspathFilesHandler.ClasspathFilesHandlerBuilder
to continue configuring the
ClasspathFilesHandler
instance.public ClasspathFilesHandler.ClasspathFilesHandlerBuilder rootDirectory(String root)
ClasspathFilesHandler.ClasspathFilesHandlerBuilder
configured with the given path as the root
directory for resources to serve.root
- the path of the root directory for resources to serve.ClasspathFilesHandler.ClasspathFilesHandlerBuilder
to continue configuring the
ClasspathFilesHandler
instance.public ClasspathFilesHandler.ClasspathFilesHandlerBuilder welcomeFile(String welcome)
ClasspathFilesHandler.ClasspathFilesHandlerBuilder
configured with the given file name as the
index.welcome
- the directory index file name to serve in case a directory is requested.ClasspathFilesHandler.ClasspathFilesHandlerBuilder
to continue configuring the
ClasspathFilesHandler
instance.