Struct arc_reactor::contrib::StaticFileServer [−][src]
A static File Server implemented as a Middleware
Fields
root: &'static str
the root url for all your files. e.g static
, assets
request urls that begin with the supplied value for root would be
matched.
public: PathBuf
Path to folder to serve your static files from.
Methods
impl StaticFileServer
[src]
impl StaticFileServer
pub fn new(root: &'static str, public: PathBuf) -> Self
[src]
pub fn new(root: &'static str, public: PathBuf) -> Self
Creates a StaticFileServer with the given root and pathbuf.
Trait Implementations
impl Clone for StaticFileServer
[src]
impl Clone for StaticFileServer
fn clone(&self) -> StaticFileServer
[src]
fn clone(&self) -> StaticFileServer
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
1.0.0
[src]Performs copy-assignment from source
. Read more
impl Debug for StaticFileServer
[src]
impl Debug for StaticFileServer
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl MiddleWare<Request> for StaticFileServer
[src]
impl MiddleWare<Request> for StaticFileServer
fn call(&self, req: Request) -> MiddleWareFuture<Request>
[src]
fn call(&self, req: Request) -> MiddleWareFuture<Request>
Auto Trait Implementations
impl Send for StaticFileServer
impl Send for StaticFileServer
impl Sync for StaticFileServer
impl Sync for StaticFileServer