lib/packetgen/header/http/headers.rb in packetgen-2.2.0 vs lib/packetgen/header/http/headers.rb in packetgen-2.3.0
- old
+ new
@@ -14,11 +14,11 @@
def initialize
@data = nil
end
# Populate object from a string or directly from a hash.
- # @param [String, Hash]
+ # @param [String, Hash] s_or_h
# @return [self]
def read(s_or_h)
case s_or_h
when String
@data = s_or_h.split("\n").map do |h|
@@ -49,10 +49,10 @@
def to_human
@data
end
# Read human-readable data to populate header data.
- # @param [String, Hash]
+ # @param [String, Hash] data
# @return [self]
def from_human(data)
read(data)
end