class Pio::Icmp
Icmp
parser and generator.
ICMP parser and generator
Public Class Methods
read(raw_data)
click to toggle source
# File lib/pio/icmp.rb, line 11 def self.read(raw_data) format = Format.read(raw_data) { Request.icmp_type => Request, Reply.icmp_type => Reply }.fetch(format.icmp_type).create(format) rescue raise Pio::ParseError, $ERROR_INFO.message end