Package org.alfresco.repo.web.util
Class HttpRangeProcessor
- java.lang.Object
-
- org.alfresco.repo.web.util.HttpRangeProcessor
-
public class HttpRangeProcessor extends Object
Generates HTTP response for "Range" scoped HTTP requests for content.
-
-
Constructor Summary
Constructors Constructor Description HttpRangeProcessor(ContentService contentService)
Constructor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
processRange(javax.servlet.http.HttpServletResponse res, ContentReader reader, String range, NodeRef ref, QName property, String mimetype, String userAgent)
Process a range header for a HttpServletResponse - handles single and multiple range requests.boolean
processRange(org.springframework.extensions.webscripts.WebScriptResponse res, ContentReader reader, String range, NodeRef ref, QName property, String mimetype, String userAgent)
Process a range header for a WebScriptResponse - handles single and multiple range requests.
-
-
-
Constructor Detail
-
HttpRangeProcessor
public HttpRangeProcessor(ContentService contentService)
Constructor.- Parameters:
contentService
- ContentService
-
-
Method Detail
-
processRange
public boolean processRange(javax.servlet.http.HttpServletResponse res, ContentReader reader, String range, NodeRef ref, QName property, String mimetype, String userAgent) throws IOException
Process a range header for a HttpServletResponse - handles single and multiple range requests.- Parameters:
res
- the HTTP servlet responsereader
- the content readerrange
- the byte rangeref
- the content NodeRefproperty
- the content propertymimetype
- the content mimetypeuserAgent
- the user agent string- Returns:
- whether or not the range could be processed
- Throws:
IOException
-
processRange
public boolean processRange(org.springframework.extensions.webscripts.WebScriptResponse res, ContentReader reader, String range, NodeRef ref, QName property, String mimetype, String userAgent) throws IOException
Process a range header for a WebScriptResponse - handles single and multiple range requests.- Parameters:
res
- the webscript responsereader
- the content readerrange
- the byte rangeref
- the content NodeRefproperty
- the content propertymimetype
- the content mimetypeuserAgent
- the user agent string- Returns:
- whether or not the range could be processed
- Throws:
IOException
-
-