class String

Public Instance Methods

eat_lines() { |self| ... } click to toggle source
# File lib/hermes/message.rb, line 17
def eat_lines
  @pos ||= 0
  while @pos < length do
    p = index /.*\n?/, @pos
    l = $&.length
    begin
      yield self[ @pos, l]
    ensure
      @pos += l
    end
  end
end
rewind() click to toggle source
# File lib/hermes/message.rb, line 29
def rewind
  @pos = 0
end
to_gray() click to toggle source
# File lib/hermes/color.rb, line 258
def to_gray
  (Integer self).to_gray
end
Also aliased as: to_grey
to_grey()
Alias for: to_gray
to_rgb() click to toggle source
# File lib/hermes/color.rb, line 262
def to_rgb
  Hermes::Color.from_s self
end