SectorIdentifierService
in package
Table of Contents
Methods
- next() : string|null
- Generate the next identifier for a sector, or null when the sector mask is disabled / not configured (caller passes through the user-supplied identifier on null).
- previewInfo() : array<string|int, mixed>|null
- Preview the next identifier for a sector WITHOUT consuming the counter - the create form's identifierGenerator component uses this so the preview it shows matches what next() produces at save time.
- resolveSector() : string|null
- Resolve a free-form source_standard value to one of the five sector codes the settings page knows about. Returns null when nothing matches.
Methods
next()
Generate the next identifier for a sector, or null when the sector mask is disabled / not configured (caller passes through the user-supplied identifier on null).
public
static next(string|null $sectorCode) : string|null
Parameters
- $sectorCode : string|null
Return values
string|nullpreviewInfo()
Preview the next identifier for a sector WITHOUT consuming the counter - the create form's identifierGenerator component uses this so the preview it shows matches what next() produces at save time.
public
static previewInfo(string|null $sectorCode) : array<string|int, mixed>|null
Returns ['next_reference','pattern','scope'] or null when no mask applies (caller should fall through to the legacy NumberingService).
Parameters
- $sectorCode : string|null
Return values
array<string|int, mixed>|nullresolveSector()
Resolve a free-form source_standard value to one of the five sector codes the settings page knows about. Returns null when nothing matches.
public
static resolveSector(string|null $sourceStandard) : string|null
Parameters
- $sourceStandard : string|null