interface NumberConverterInterface
A number converter converts UUIDs from hexadecimal characters into representations of integers and vice versa
@psalm-immutable
Hierarchy
- interface \Ramsey\Uuid\Converter\NumberConverterInterface
Expanded class hierarchy of NumberConverterInterface
All classes that implement NumberConverterInterface
24 files declare their use of NumberConverterInterface
- BigNumberConverter.php in vendor/
ramsey/ uuid/ src/ Converter/ Number/ BigNumberConverter.php - CombGenerator.php in vendor/
ramsey/ uuid/ src/ Generator/ CombGenerator.php - DceSecurityGenerator.php in vendor/
ramsey/ uuid/ src/ Generator/ DceSecurityGenerator.php - DegradedUuidBuilder.php in vendor/
ramsey/ uuid/ src/ Builder/ DegradedUuidBuilder.php - DeprecatedUuidInterface.php in vendor/
ramsey/ uuid/ src/ DeprecatedUuidInterface.php
File
-
vendor/
ramsey/ uuid/ src/ Converter/ NumberConverterInterface.php, line 23
Namespace
Ramsey\Uuid\ConverterView source
interface NumberConverterInterface {
/**
* Converts a hexadecimal number into an string integer representation of
* the number
*
* The integer representation returned is a string representation of the
* integer, to accommodate unsigned integers greater than PHP_INT_MAX.
*
* @param string $hex The hexadecimal string representation to convert
*
* @return string String representation of an integer
*
* @psalm-return numeric-string
*
* @psalm-pure
*/
public function fromHex(string $hex) : string;
/**
* Converts a string integer representation into a hexadecimal string
* representation of the number
*
* @param string $number A string integer representation to convert; this
* must be a numeric string to accommodate unsigned integers greater
* than PHP_INT_MAX.
*
* @return string Hexadecimal string
*
* @psalm-return non-empty-string
*
* @psalm-pure
*/
public function toHex(string $number) : string;
}
Members
Title Sort descending | Modifiers | Object type | Summary | Overrides |
---|---|---|---|---|
NumberConverterInterface::fromHex | public | function | Converts a hexadecimal number into an string integer representation of the number |
2 |
NumberConverterInterface::toHex | public | function | Converts a string integer representation into a hexadecimal string representation of the number |
2 |