Class: String
- Inherits:
-
Object
- Object
- String
- Defined in:
- lib/rfeedparser/encoding_helpers.rb
Instance Method Summary collapse
Instance Method Details
#to_xs ⇒ Object
254 255 256 257 258 |
# File 'lib/rfeedparser/encoding_helpers.rb', line 254 def to_xs unpack('U*').map {|n| n.xchr}.join # ASCII, UTF-8 rescue unpack('C*').map {|n| n.xchr}.join # ISO-8859-1, WIN-1252 end |