Support for the Ruby 2.1 series ended on March 31 2017. See here for details.

In Files

  • rubygems/util/stringio.rb

Parent

Class/Module Index [+]

Quicksearch

Gem::StringSink

Attributes

string[R]

Public Class Methods

new() click to toggle source
 
               # File rubygems/util/stringio.rb, line 2
def initialize
  @string = ""
end
            

Public Instance Methods

set_encoding(enc) click to toggle source
 
               # File rubygems/util/stringio.rb, line 13
def set_encoding(enc)
  @string.force_encoding enc
end
            
write(s) click to toggle source
 
               # File rubygems/util/stringio.rb, line 8
def write(s)
  @string += s
  s.size
end