class Socket::Ifaddr
Socket::Ifaddr represents a result of getifaddrs() function.
Public Instance Methods
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/stdlib/socket/0/socket.rbs, line 3756
def addr: () -> Addrinfo?
Returns the address of ifaddr. nil is returned if address is not available in ifaddr.
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/stdlib/socket/0/socket.rbs, line 3765
def broadaddr: () -> Addrinfo?
Returns the broadcast address of ifaddr. nil is returned if the flags doesn’t have IFF_BROADCAST.
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/stdlib/socket/0/socket.rbs, line 3774
def dstaddr: () -> Addrinfo?
Returns the destination address of ifaddr. nil is returned if the flags doesn’t have IFF_POINTOPOINT.
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/stdlib/socket/0/socket.rbs, line 3785
def flags: () -> Integer
Returns the flags of ifaddr.
The value is bitwise-or of Socket::IFF_* constants such as Socket::IFF_LOOPBACK.
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/stdlib/socket/0/socket.rbs, line 3793
def ifindex: () -> Integer
Returns the interface index of ifaddr.
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/stdlib/socket/0/socket.rbs, line 3801
def inspect: () -> String
Returns a string to show contents of ifaddr.
# File vendor/bundle/ruby/4.0.0/gems/rbs-4.0.3/stdlib/socket/0/socket.rbs, line 3809
def name: () -> String
Returns the interface name of ifaddr.