AbstractUid
in package
implements
JsonSerializable
AbstractYes
Tags
Table of Contents
Interfaces
- JsonSerializable
Properties
- $uid : mixed
- The identifier in its canonic representation.
Methods
- __toString() : string
- compare() : int
- equals() : bool
- Returns whether the argument is an AbstractUid and contains the same value as the current instance.
- fromBase32() : static
- fromBase58() : static
- fromBinary() : static
- fromRfc4122() : static
- fromString() : static
- Creates an AbstractUid from an identifier represented in any of the supported formats.
- isValid() : bool
- Whether the passed value is valid for the constructor of the current class.
- jsonSerialize() : string
- toBase32() : string
- Returns the identifier as a base32 case insensitive string.
- toBase58() : string
- Returns the identifier as a base58 case sensitive string.
- toBinary() : string
- Returns the identifier as a raw binary string.
- toRfc4122() : string
- Returns the identifier as a RFC4122 case insensitive string.
Properties
$uid
The identifier in its canonic representation.
protected
mixed
$uid
Methods
__toString()
public
__toString() : string
Return values
stringcompare()
public
compare(self $other) : int
Parameters
- $other : self
Return values
intequals()
Returns whether the argument is an AbstractUid and contains the same value as the current instance.
public
equals(mixed $other) : bool
Parameters
- $other : mixed
Return values
boolfromBase32()
public
static fromBase32(string $uid) : static
Parameters
- $uid : string
Tags
Return values
staticfromBase58()
public
static fromBase58(string $uid) : static
Parameters
- $uid : string
Tags
Return values
staticfromBinary()
public
static fromBinary(string $uid) : static
Parameters
- $uid : string
Tags
Return values
staticfromRfc4122()
public
static fromRfc4122(string $uid) : static
Parameters
- $uid : string
Tags
Return values
staticfromString()
Creates an AbstractUid from an identifier represented in any of the supported formats.
public
abstract static fromString(string $uid) : static
Parameters
- $uid : string
Tags
Return values
staticisValid()
Whether the passed value is valid for the constructor of the current class.
public
abstract static isValid(string $uid) : bool
Parameters
- $uid : string
Return values
booljsonSerialize()
public
jsonSerialize() : string
Return values
stringtoBase32()
Returns the identifier as a base32 case insensitive string.
public
toBase32() : string
Return values
stringtoBase58()
Returns the identifier as a base58 case sensitive string.
public
toBase58() : string
Return values
stringtoBinary()
Returns the identifier as a raw binary string.
public
abstract toBinary() : string
Return values
stringtoRfc4122()
Returns the identifier as a RFC4122 case insensitive string.
public
toRfc4122() : string