Struct http_file_headers::FileWrapper [−][src]
pub struct FileWrapper { /* fields omitted */ }Structure that contains all the metadata for response headers and the file which will be sent in response body.
Methods
impl FileWrapper[src]
impl FileWrapperpub fn is_partial(&self) -> bool[src]
pub fn is_partial(&self) -> boolReturns true if response contains partial content (206)
pub fn content_length(&self) -> u64[src]
pub fn content_length(&self) -> u64Returns the value of Content-Length header that should be sent
pub fn headers(&self) -> HeaderIter[src]
pub fn headers(&self) -> HeaderIterReturns the iterator over headers to send in response
Note: this does not include Content-Length header,
use content_length() method explicitly.
pub fn read_chunk<O>(&mut self, output: O) -> Result<usize> where
O: Write, [src]
pub fn read_chunk<O>(&mut self, output: O) -> Result<usize> where
O: Write, Read chunk from file into an output file
Must be run in disk thread
Trait Implementations
impl Debug for FileWrapper[src]
impl Debug for FileWrapperAuto Trait Implementations
impl Send for FileWrapper
impl Send for FileWrapperimpl Sync for FileWrapper
impl Sync for FileWrapper