IDGenerator
    
            
            in package
            
        
    
    
    
        
        
    
Table of Contents
- $constraints : mixed
 - $auditLogs : mixed
 - $config : mixed
 - $delimiter : mixed
 - $existingIDs : mixed
 - $format : mixed
 - $hashAlgorithm : mixed
 - $Id : mixed
 - $idLength : mixed
 - $maxRetries : mixed
 - $prefix : mixed
 - $randomLength : mixed
 - $sequenceStart : mixed
 - $suffix : mixed
 - $tenantId : mixed
 - __construct() : mixed
 - generateID() : mixed
 - getExistingIDs() : mixed
 - getID() : mixed
 - getTenantId() : mixed
 - Retrieves the tenant ID based on the provided or current ID.
 - setTenantId() : void
 - getConfig() : mixed
 - applyPrefixSuffix() : mixed
 - enforceLengthConstraints() : mixed
 - generateHashID() : null|string
 - Generate a hashed identifier based on a random string and specified hash algorithm.
 - generateNumberID() : mixed
 - generateRandomID() : mixed
 - generateUUID() : mixed
 - randomNumericString() : mixed
 - validateConfig() : void
 
Properties
$constraints
    public
        mixed
    $constraints
    
        
        
    
$auditLogs
    private
        mixed
    $auditLogs
    
        
        
    
$config
    private
        mixed
    $config
    
        
        
    
$delimiter
    private
        mixed
    $delimiter
    
        
        
    
$existingIDs
    private
        mixed
    $existingIDs
    
        
        
    
$format
    private
        mixed
    $format
    
        
        
    
$hashAlgorithm
    private
        mixed
    $hashAlgorithm
    
        
        
    
$Id
    private
        mixed
    $Id
    
        
        
    
$idLength
    private
        mixed
    $idLength
    
        
        
    
$maxRetries
    private
        mixed
    $maxRetries
    
        
        
    
$prefix
    private
        mixed
    $prefix
    
        
        
    
$randomLength
    private
        mixed
    $randomLength
    
        
        
    
$sequenceStart
    private
        mixed
    $sequenceStart
    
        
        
    
$suffix
    private
        mixed
    $suffix
    
        
        
    
$tenantId
    private
        mixed
    $tenantId
    
        
        
    
Methods
__construct()
    public
                    __construct(array<string|int, mixed> $tenantConfig[, array<string|int, mixed> $existingIDs = [] ]) : mixed
        
        Parameters
- $tenantConfig : array<string|int, mixed>
 - $existingIDs : array<string|int, mixed> = []
 
Return values
mixed —generateID()
    public
                    generateID() : mixed
        
    
    
        Return values
mixed —getExistingIDs()
    public
                    getExistingIDs() : mixed
        
    
    
        Return values
mixed —getID()
    public
                    getID() : mixed
        
    
    
        Return values
mixed —getTenantId()
Retrieves the tenant ID based on the provided or current ID.
    public
                    getTenantId([null|string $id = null ]) : mixed
        If no ID is provided, it attempts to retrieve the tenant ID associated with the current object's ID. If an ID is provided, it looks for the tenant ID associated with that ID.
Parameters
- $id : null|string = null
 - 
                    
Optional. The ID to look up. Defaults to null.
 
Return values
mixed —The tenant ID if found, or null if not available.
setTenantId()
    public
                    setTenantId(mixed $id) : void
        
        Parameters
- $id : mixed
 
Return values
void —getConfig()
    protected
                    getConfig(string $key[, null|int $default = null ]) : mixed
    
        Parameters
- $key : string
 - $default : null|int = null
 
Tags
Return values
mixed —applyPrefixSuffix()
    private
                    applyPrefixSuffix(mixed $id) : mixed
        
        Parameters
- $id : mixed
 
Return values
mixed —enforceLengthConstraints()
    private
                    enforceLengthConstraints(false|string $id) : mixed
    
        Parameters
- $id : false|string
 
Return values
mixed —generateHashID()
Generate a hashed identifier based on a random string and specified hash algorithm.
    private
                    generateHashID() : null|string
    
    
    
    Tags
Return values
null|string —The generated hash ID or null if no algorithm is provided.
generateNumberID()
    private
                    generateNumberID() : mixed
        
    
    
        Return values
mixed —generateRandomID()
    private
                    generateRandomID() : mixed
        
    
    
        Return values
mixed —generateUUID()
    private
                    generateUUID() : mixed
        
    
    
        Return values
mixed —randomNumericString()
    private
                    randomNumericString(mixed $length) : mixed
        
        Parameters
- $length : mixed
 
Return values
mixed —validateConfig()
    private
                    validateConfig() : void