Class StaticResourceServer
java.lang.Object
com.spec.web.expresso.middleware.MiddlewareMetaData
com.spec.web.expresso.middleware.standard.StaticResourceServer
Hosts the static files contained in /resrouces folder.
-
Constructor Summary
ConstructorsConstructorDescriptionStaticResourceServer(String staticResourcePath) Create an instance of class with a staticResourcePath -
Method Summary
Modifier and TypeMethodDescriptioncom.spec.web.expresso.middleware.standard.StaticResourceServerMiddlewareReturns the middleware registered on the following StaticResourceServer.voidThe middleware needs to know on what path(URL path on web) it is registered.Methods inherited from class com.spec.web.expresso.middleware.MiddlewareMetaData
addPrefixPath, appendPath, calcPath, copy, getMethod, getPath, setMethod, toString
-
Constructor Details
-
StaticResourceServer
Create an instance of class with a staticResourcePath- Parameters:
staticResourcePath- Path to the folder containing static files
-
-
Method Details
-
setPath
The middleware needs to know on what path(URL path on web) it is registered. The following method passes the registered url path to the middleware.- Overrides:
setPathin classMiddlewareMetaData- Parameters:
pathString- The string containing the path.
-
getMiddleware
public com.spec.web.expresso.middleware.standard.StaticResourceServerMiddleware getMiddleware()Returns the middleware registered on the following StaticResourceServer.- Overrides:
getMiddlewarein classMiddlewareMetaData- Returns:
- Instance of middleware.
-