Module
Module documentation.
modulecrypto.rand
Classes
Classes and inheritance.
Functions
Free functions and class methods.
functioncrypto.rand::__rand_hex
Signature
extern func __rand_hex(nbytes: Int) -> String;extern func __rand_hex(nbytes: Int) -> String;
/*@briefBinds the low-level runtime symbol `__rand_hex`.
@detailsThis function is an external entry point used by system modules to access native runtime capabilities such as filesystem, networking, threading, GC, cryptography, or platform operations. Prefer the safe wrapper functions in the same file when available. When calling this entry directly, pass validated arguments that match the signature and handle failures according to the return-value convention.
@param
- nbytesSize or length value that limits how much data the operation processes.
@returnReturns the operation result as `String`.
functioncrypto.rand::hex
Signature
func hex(nbytes: Int) -> Stringfunc hex(nbytes: Int) -> String {
return __rand_hex(nbytes);
}@briefProvides the system library operation `hex`.
@detailsExecutes the `hex` system-library API. The documented parameters define the accepted inputs, ownership requirements, range limits, and timeout behavior for this call. Callers must check returned `ErrCode` values or boolean status values before using the result.
@param
- nbytesSize or length value that limits how much data the operation processes.
@returnReturns the operation result as `String`.
Variables
Class fields (var).