mirror of
https://github.com/ramsey/uuid.git
synced 2026-07-01 18:37:06 +03:00
Refining type of producing a string that can be declared as non-empty-string
This commit is contained in:
committed by
Ben Ramsey
parent
2108274b4a
commit
598b47d07f
@@ -61,6 +61,8 @@ interface UuidInterface extends
|
||||
|
||||
/**
|
||||
* Returns the binary string representation of the UUID
|
||||
*
|
||||
* @psalm-return non-empty-string
|
||||
*/
|
||||
public function getBytes(): string;
|
||||
|
||||
@@ -71,21 +73,29 @@ interface UuidInterface extends
|
||||
|
||||
/**
|
||||
* Returns the hexadecimal string representation of the UUID
|
||||
*
|
||||
* @psalm-return non-empty-string
|
||||
*/
|
||||
public function getHex(): string;
|
||||
|
||||
/**
|
||||
* Returns the integer value of the UUID as a string
|
||||
*
|
||||
* @psalm-return non-empty-string
|
||||
*/
|
||||
public function getInteger(): string;
|
||||
|
||||
/**
|
||||
* Returns a string representation of the UUID
|
||||
*
|
||||
* @psalm-return non-empty-string
|
||||
*/
|
||||
public function toString(): string;
|
||||
|
||||
/**
|
||||
* Casts the UUID to a string representation
|
||||
*
|
||||
* @psalm-return non-empty-string
|
||||
*/
|
||||
public function __toString(): string;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user