class

Magic::Error

Inherits SystemError / Exception / Reference / Object

An error encountered while communicating with the C libmagic API.

Macros

from_errno(message, **opts)

Builds an instance of the exception from the current system error value (Errno.value).

The system message corresponding to the OS error value amends the message. Additional keyword arguments are forwarded to the exception initializer .new_from_os_error.

Source
from_errno(message = nil, errno = nil, **opts)

DEPRECATED Use .from_os_error instead

Source
from_winerror(message, **opts)

Builds an instance of the exception from the current windows error value (WinError.value).

The system message corresponding to the OS error value amends the message. Additional keyword arguments are forwarded to the exception initializer .new_from_os_error.

Source
from_wsa_error(message = nil, **opts)

Builds an instance of the exception from the current Windows Socket API error value (WinError.wsa_value).

The system message corresponding to the OS error value amends the message. Additional keyword arguments are forwarded to the exception initializer.

Source