Function next [src]

Call nextSize to get the length of the next variable name and check if buffer is large enough to hold the name.

Prototype

pub fn next( self: *VariableNameIterator, ) IterateVariableNameError!?[:0]const u16

Parameters

self: *VariableNameIterator

Possible Errors

BufferTooSmall
DeviceError NextSizeError
Unexpected UnexpectedError
Unsupported NextSizeError

Source

pub fn next( self: *VariableNameIterator, ) IterateVariableNameError!?[:0]const u16 { var len = self.buffer.len; switch (self.services._getNextVariableName( &len, @ptrCast(self.buffer.ptr), &self.guid, )) { .success => return self.buffer[0 .. len - 1 :0], .not_found => return null, .buffer_too_small => return error.BufferTooSmall, .device_error => return error.DeviceError, .unsupported => return error.Unsupported, else => |status| return uefi.unexpectedStatus(status), } }