Binary
final class Binary implements Type, BinaryInterface, Serializable, JsonSerializable (View source)
Class Binary
Constants
TYPE_GENERIC |
|
TYPE_FUNCTION |
|
TYPE_OLD_BINARY |
|
TYPE_OLD_UUID |
|
TYPE_UUID |
|
TYPE_MD5 |
|
TYPE_ENCRYPTED
Since: 1.7.0
|
|
TYPE_COLUMN
Since: 1.12.0
|
|
TYPE_USER_DEFINED |
|
Methods
__construct(string $data, int $type = Binary::TYPE_GENERIC)
Binary constructor.
string
getData()
Returns the Binary's data
int
getType()
Returns the Binary's type
static
__set_state(array $properties)
No description
string
__toString()
Returns the Binary's data
string|null
serialize()
Serialize a Binary
void
unserialize(string $data)
Unserialize a Binary
mixed
jsonSerialize()
Returns a representation that can be converted to JSON
Details
final
__construct(string $data, int $type = Binary::TYPE_GENERIC)
Binary constructor.
final string
getData()
Returns the Binary's data
final int
getType()
Returns the Binary's type
static
__set_state(array $properties)
No description
final string
__toString()
Returns the Binary's data
final string|null
serialize()
Since: 1.2.0
Serialize a Binary
final void
unserialize(string $data)
Since: 1.2.0
Unserialize a Binary
final mixed
jsonSerialize()
Since: 1.2.0
Returns a representation that can be converted to JSON