class AcceptHeaderItem
Represents an Accept-* header item.
Methods
__construct(string $value, array $attributes = array()) Constructor. | ||
static AcceptHeaderItem | fromString(string $itemValue) Builds an AcceptHeaderInstance instance from a string. | |
string | __toString() Returns header value's string representation. | |
AcceptHeaderItem | setValue(string $value) Set the item value. | |
string | getValue() Returns the item value. | |
AcceptHeaderItem | setQuality(float $quality) Set the item quality. | |
float | getQuality() Returns the item quality. | |
AcceptHeaderItem | setIndex(int $index) Set the item index. | |
int | getIndex() Returns the item index. | |
bool | hasAttribute(string $name) Tests if an attribute exists. | |
mixed | getAttribute(string $name, mixed $default = null) Returns an attribute by its name. | |
array | getAttributes() Returns all attributes. | |
AcceptHeaderItem | setAttribute(string $name, string $value) Set an attribute. |
Details
__construct(string $value, array $attributes = array())
Constructor.
static AcceptHeaderItem fromString(string $itemValue)
Builds an AcceptHeaderInstance instance from a string.
string __toString()
Returns header value's string representation.
AcceptHeaderItem setValue(string $value)
Set the item value.
string getValue()
Returns the item value.
AcceptHeaderItem setQuality(float $quality)
Set the item quality.
float getQuality()
Returns the item quality.
AcceptHeaderItem setIndex(int $index)
Set the item index.
int getIndex()
Returns the item index.
bool hasAttribute(string $name)
Tests if an attribute exists.
mixed getAttribute(string $name, mixed $default = null)
Returns an attribute by its name.
array getAttributes()
Returns all attributes.
AcceptHeaderItem setAttribute(string $name, string $value)
Set an attribute.
Please login to continue.