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 Details

    • HttpRangeProcessor

      public HttpRangeProcessor(ContentService contentService)
      Constructor.
      Parameters:
      contentService - ContentService
  • Method Details

    • processRange

      public boolean processRange(javax.servlet.http.HttpServletResponse res, ContentReader reader, String range, NodeRef ref, org.alfresco.service.namespace.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 response
      reader - the content reader
      range - the byte range
      ref - the content NodeRef
      property - the content property
      mimetype - the content mimetype
      userAgent - 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, org.alfresco.service.namespace.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 response
      reader - the content reader
      range - the byte range
      ref - the content NodeRef
      property - the content property
      mimetype - the content mimetype
      userAgent - the user agent string
      Returns:
      whether or not the range could be processed
      Throws:
      IOException