ICanBoogie
  • Documentation
  • API Reference
  • HTTP master
Namespaces
  • ICanBoogie
    • Exception
    • HTTP
      • Headers
      • Request
      • RequestDispatcher
Classes
  • CallableDispatcher
  • DispatcherProvider
  • File
  • FileInfo
  • FileList
  • FileResponse
  • Headers
  • ProvideDispatcher
  • RedirectResponse
  • Request
  • RequestDispatcher
  • RequestOptionsMapper
  • RequestRange
  • Response
  • Status
  • WeightedDispatcher
Interfaces
  • Dispatcher
  • Exception
  • FileOptions
  • RequestMethods
  • RequestOptions
  • ResponseStatus
  • SecurityError
Exceptions
  • AuthenticationRequired
  • ClientError
  • DispatcherNotDefined
  • DispatcherProviderNotDefined
  • ForceRedirect
  • MethodNotSupported
  • NotFound
  • PermissionRequired
  • ServerError
  • ServiceUnavailable
  • StatusCodeNotValid

Class RequestRange

Representation of a request range.

ICanBoogie\HTTP\RequestRange uses ICanBoogie\Accessor\AccessorTrait (not available)
Namespace: ICanBoogie\HTTP
Located at RequestRange.php

Methods summary

public static from( ICanBoogie\HTTP\Headers $headers, integer $total, string $etag ) : ICanBoogie\HTTP\RequestRange|null

Creates a new instance.

Creates a new instance.

Parameters

$headers
$total
$etag

Returns

ICanBoogie\HTTP\RequestRange|null

A new instance, or null if the range is not defined or deprecated (because If-Range doesn't match $etag).

protected __construct( integer $start, integer $end, integer $total )

Parameters

$start
$end
$total
public __toString( void ) : string

Formats the instance as a string suitable for the Content-Range header field.

Formats the instance as a string suitable for the Content-Range header field.

Returns

string
protected get_is_satisfiable( void ) : boolean

Whether the range is satisfiable.

Whether the range is satisfiable.

Returns

boolean
protected get_is_total( void ) : boolean

Whether the range is actually the total.

Whether the range is actually the total.

Returns

boolean
protected get_length( void ) : integer

Returns the length of the range, suitable for the Content-Length header field.

Returns the length of the range, suitable for the Content-Length header field.

Returns

integer
protected get_max_length( void ) : integer

Maximum bytes to copy, suitable for the stream_copy_to_stream() function.

Maximum bytes to copy, suitable for the stream_copy_to_stream() function.

Returns

integer
protected get_offset( void ) : integer

Returns the offset where to start to copy data, suitable for the stream_copy_to_stream() function.

Returns the offset where to start to copy data, suitable for the stream_copy_to_stream() function.

Returns

integer

Properties summary

Magic properties

public $is_satisfiable : boolean

Whether the range is satisfiable.

public $is_total : boolean

Whether the range is actually the total.

public $length : integer

Length of the range, suitable for the Content-Length header field.

public $max_length : integer

Maximum bytes to copy, suitable for the stream_copy_to_stream() function.

public $offset : integer

The offset where to start to copy data, suitable for the stream_copy_to_stream() function.

HTTP master – Check on GitHub – API documentation generated by ApiGen