In Files

  • mrbgems/mruby-socket/mrblib/socket.rb

IPSocket

Public Class Methods

getaddress(host) click to toggle source
 
               # File mrbgems/mruby-socket/mrblib/socket.rb, line 212
def self.getaddress(host)
  Addrinfo.ip(host).ip_address
end
            

Public Instance Methods

addr() click to toggle source
 
               # File mrbgems/mruby-socket/mrblib/socket.rb, line 216
def addr
  Addrinfo.new(self.getsockname)._to_array
end
            
peeraddr() click to toggle source
 
               # File mrbgems/mruby-socket/mrblib/socket.rb, line 220
def peeraddr
  Addrinfo.new(self.getpeername)._to_array
end
            
recvfrom(maxlen, flags=0) click to toggle source
 
               # File mrbgems/mruby-socket/mrblib/socket.rb, line 224
def recvfrom(maxlen, flags=0)
  msg, sa = _recvfrom(maxlen, flags)
  [ msg, Addrinfo.new(sa)._to_array ]
end