Documentation
¶
Overview ¶
Package autofill provides auto-fill value generation for AppSpecConfigItem auto-fill expressions. Supported types: defval, hexstr_32, hexstr_16, uuid.
Index ¶
Constants ¶
View Source
const ( // DefVal uses the field's default value (returns empty, caller should use field.Default). DefVal = "defval" // HexStr32 generates a 32-character hex string (16 random bytes). HexStr32 = "hexstr_32" // HexStr16 generates a 16-character hex string (8 random bytes). HexStr16 = "hexstr_16" // UUID generates a UUID v4 string. UUID = "uuid" )
Variables ¶
This section is empty.
Functions ¶
func Generate ¶
Generate produces a value based on the auto-fill type. For DefVal, returns empty string — the caller should fall back to the field's Default.
func GenerateIfEmpty ¶
GenerateIfEmpty generates an auto-fill value only if the current value is empty. Returns the current value if non-empty, otherwise generates a new value.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.