ContentRangeParser (RabbIT/4)
Date: 2009-12-20

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## rabbit.http
Class ContentRangeParser

    java.lang.Object
      rabbit.http.ContentRangeParser

    public class ContentRangeParser

extends Object

A class that parses content range headers.

Author:
  Robert Olofsson

Constructor Summary
`ContentRangeParser(String cr)` Try to parse the given content range.

Method Summary
`long` | `getEnd()` Get the end index.
`long` | `getStart()` Get the start index
`long` | `getTotal()` Get the total size of the resource.
`boolean` | `isValid()` Check if the content range was valid.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### ContentRangeParser

    public ContentRangeParser(String cr)

  Try to parse the given content range.

  Parameters:
    `cr` - the Content-Range header.

Method Detail

### isValid

    public boolean isValid()

  Check if the content range was valid.

### getStart

    public long getStart()

  Get the start index

### getEnd

    public long getEnd()

  Get the end index.

### getTotal

    public long getTotal()

  Get the total size of the resource.

  Returns:
    the resource size if know or -1 if unknown ('*' was used in the content range).

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD