HttpHdrContRange.cc File Reference
#include "squid.h"
#include "base/Packable.h"
#include "debug/Stream.h"
#include "enums.h"
#include "HttpHdrContRange.h"
#include "HttpHeaderTools.h"
Include dependency graph for HttpHdrContRange.cc:

Go to the source code of this file.

Macros

#define range_spec_unknown   (-1)
 
#define known_spec(s)   ((s) != range_spec_unknown)
 
#define size_min(a, b)   ((a) <= (b) ? (a) : (b))
 
#define size_diff(a, b)   ((a) >= (b) ? ((a)-(b)) : 0)
 

Functions

static int httpHdrRangeRespSpecParseInit (HttpHdrRangeSpec *spec, const char *field, int flen)
 
static void httpHdrRangeRespSpecPackInto (const HttpHdrRangeSpec *spec, Packable *p)
 
HttpHdrContRangehttpHdrContRangeCreate (void)
 
HttpHdrContRangehttpHdrContRangeParseCreate (const char *str)
 
int httpHdrContRangeParseInit (HttpHdrContRange *range, const char *str)
 
HttpHdrContRangehttpHdrContRangeDup (const HttpHdrContRange *range)
 
void httpHdrContRangePackInto (const HttpHdrContRange *range, Packable *p)
 
void httpHdrContRangeSet (HttpHdrContRange *cr, HttpHdrRangeSpec spec, int64_t ent_len)
 

Macro Definition Documentation

◆ known_spec

#define known_spec (   s)    ((s) != range_spec_unknown)

Definition at line 34 of file HttpHdrContRange.cc.

◆ range_spec_unknown

#define range_spec_unknown   (-1)

Definition at line 31 of file HttpHdrContRange.cc.

◆ size_diff

#define size_diff (   a,
 
)    ((a) >= (b) ? ((a)-(b)) : 0)

Definition at line 36 of file HttpHdrContRange.cc.

◆ size_min

#define size_min (   a,
 
)    ((a) <= (b) ? (a) : (b))

Definition at line 35 of file HttpHdrContRange.cc.

Function Documentation

◆ httpHdrContRangeCreate()

◆ httpHdrContRangeDup()

HttpHdrContRange * httpHdrContRangeDup ( const HttpHdrContRange range)

Definition at line 196 of file HttpHdrContRange.cc.

References assert, and httpHdrContRangeCreate().

◆ httpHdrContRangePackInto()

void httpHdrContRangePackInto ( const HttpHdrContRange range,
Packable p 
)

◆ httpHdrContRangeParseCreate()

HttpHdrContRange * httpHdrContRangeParseCreate ( const char *  str)

Definition at line 127 of file HttpHdrContRange.cc.

References httpHdrContRangeCreate(), and httpHdrContRangeParseInit().

Referenced by HttpHeader::getContRange().

◆ httpHdrContRangeParseInit()

int httpHdrContRangeParseInit ( HttpHdrContRange crange,
const char *  crange_spec 
)

◆ httpHdrContRangeSet()

void httpHdrContRangeSet ( HttpHdrContRange cr,
HttpHdrRangeSpec  spec,
int64_t  ent_len 
)

inits with given spec

Definition at line 220 of file HttpHdrContRange.cc.

References assert, HttpHdrContRange::elength, and HttpHdrContRange::spec.

Referenced by httpHeaderAddContRange().

◆ httpHdrRangeRespSpecPackInto()

static void httpHdrRangeRespSpecPackInto ( const HttpHdrRangeSpec spec,
Packable p 
)
static

◆ httpHdrRangeRespSpecParseInit()

static int httpHdrRangeRespSpecParseInit ( HttpHdrRangeSpec spec,
const char *  field,
int  flen 
)
static

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors