Spreadsheet::Encodings

Methods for Encoding-conversions. You should not need to use any of these.

Public Instance Methods

client(string, internal='UTF-16LE') click to toggle source
# File lib/spreadsheet/encodings.rb, line 9
def client string, internal='UTF-16LE'
  string = string.dup
  string.force_encoding internal
  string.encode Spreadsheet.client_encoding
end
internal(string, client=Spreadsheet.client_encoding) click to toggle source
# File lib/spreadsheet/encodings.rb, line 14
def internal string, client=Spreadsheet.client_encoding
  string = string.dup
  string.force_encoding client
  string.encode('UTF-16LE').force_encoding('ASCII-8BIT')
end
utf8(string, client=Spreadsheet.client_encoding) click to toggle source
# File lib/spreadsheet/encodings.rb, line 19
def utf8 string, client=Spreadsheet.client_encoding
  string = string.dup
  string.force_encoding client
  string.encode('UTF-8')
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.