Module utils

Module utils 

Source
Expand description

§UMICP Utilities

Utility functions for UMICP operations.

Functions§

base64_decode
Base64 decode data
base64_encode
Base64 encode data
compare_versions
Compare versions
format_bytes
Convert bytes to human readable format
format_duration
Get elapsed time in human readable format
generate_hash
Generate SHA-256 hash of data
generate_uuid
Generate a new UUID v4
get_current_timestamp
Get current timestamp in ISO 8601 format
is_ascii_only
Check if string contains only ASCII characters
parse_timestamp
Parse timestamp from ISO 8601 format
parse_version
Parse version string
sanitize_string
Sanitize string for safe usage
truncate_string
Truncate string to maximum length
validate_index
Validate that an index is within bounds
validate_non_empty
Validate that a string is not empty
validate_positive
Validate that a number is positive
validate_uuid
Validate UUID format