public class SpincastConfig extends Object implements ISpincastConfig
| Constructor and Description |
|---|
SpincastConfig() |
| Modifier and Type | Method and Description |
|---|---|
List<String> |
getContentTypesToSkipGziping()
Even if gziping of the response is enabled, those Content-Types
still won't be gzipped.
|
Locale |
getDefaultLocale()
The default Locale to use if no other Locale can be found
as a "best match", for the current request.
|
String |
getEnvironmentName()
Returns the name of the environment.
|
int |
getHttpServerPort()
The HTTP (unsecure) port on which the server will listen on.
|
String |
getHttpsKeyStoreKeypass()
The "keypass" of the
KeyStore, for SSL. |
String |
getHttpsKeyStorePath()
The path to the
KeyStore, for SSL. |
String |
getHttpsKeyStoreStorePass()
The "storepass" of the
KeyStore, for SSL. |
String |
getHttpsKeyStoreType()
The type of the
KeyStore, for SSL. |
int |
getHttpsServerPort()
The HTTPS (secure) port on which the server will listen on.
|
int |
getRouteForwardingMaxNumber()
The maximum number of time a request can be forwarded to another
route.
|
String |
getServerHost()
The host/IP on which the server will listen to.
|
long |
getServerMaxRequestBodyBytes()
Maximum number of bytes a request's body can have.
|
File |
getSpincastWritableDir()
A directory where generated files and temporary files
can be written by Spincast.
|
boolean |
isDebugEnabled()
Let this to
true on development environment,
where errors can be publicly displayed, where cache can
be disabled, etc. |
boolean |
isRoutesCaseSensitive()
Are the URLS case-sensitive or not, during the route matching
process?
The default value is
false. |
public String getEnvironmentName()
ISpincastConfiglocal.getEnvironmentName in interface ISpincastConfigpublic int getHttpServerPort()
ISpincastConfig44419 so HTTP
is enabled by default.getHttpServerPort in interface ISpincastConfigpublic int getHttpsServerPort()
ISpincastConfig-1 so HTTPS
is not enabled by default.getHttpsServerPort in interface ISpincastConfigpublic String getHttpsKeyStorePath()
ISpincastConfigKeyStore, for SSL. Can be a
classpath path or and absolute path.
The classpath will be checked first.
Only used if getHttpsServerPort() returns a port > 0.
The default value is null.getHttpsKeyStorePath in interface ISpincastConfigKeyStorepublic String getHttpsKeyStoreType()
ISpincastConfigKeyStore, for SSL.
For example: "JKS".
Only used if getHttpsServerPort() returns a port > 0.
The default value is null.getHttpsKeyStoreType in interface ISpincastConfigKeyStorepublic String getHttpsKeyStoreStorePass()
ISpincastConfigKeyStore, for SSL.
Only used if getHttpsServerPort() returns a port > 0.
The default value is null.getHttpsKeyStoreStorePass in interface ISpincastConfigKeyStorepublic String getHttpsKeyStoreKeypass()
ISpincastConfigKeyStore, for SSL.
Only used if getHttpsServerPort() returns a port > 0.
The default value is null.getHttpsKeyStoreKeypass in interface ISpincastConfigKeyStorepublic String getServerHost()
ISpincastConfig0.0.0.0.getServerHost in interface ISpincastConfigpublic boolean isDebugEnabled()
ISpincastConfigtrue on development environment,
where errors can be publicly displayed, where cache can
be disabled, etc. In production set it to false
The default value is true.isDebugEnabled in interface ISpincastConfigtrue if debug mode is enabled.public boolean isRoutesCaseSensitive()
ISpincastConfigfalse.isRoutesCaseSensitive in interface ISpincastConfigpublic long getServerMaxRequestBodyBytes()
ISpincastConfig104857600 (100MB).getServerMaxRequestBodyBytes in interface ISpincastConfigpublic List<String> getContentTypesToSkipGziping()
ISpincastConfiggetContentTypesToSkipGziping in interface ISpincastConfigpublic File getSpincastWritableDir()
ISpincastConfigSystem.getProperty("java.io.tmpdir")
to create a temporary directory.getSpincastWritableDir in interface ISpincastConfigpublic Locale getDefaultLocale()
ISpincastConfigLocale.US.getDefaultLocale in interface ISpincastConfigpublic int getRouteForwardingMaxNumber()
ISpincastConfig2.getRouteForwardingMaxNumber in interface ISpincastConfigCopyright © 2016. All rights reserved.