Class: UriEncoding::Decoder
- Inherits:
-
Object
- Object
- UriEncoding::Decoder
- Defined in:
- lib/uri_encoding/decoder.rb
Constant Summary collapse
- EncodedCharRegexp =
/^%([0-9A-Fa-f]{2})$/
Instance Method Summary collapse
Instance Method Details
#decode(str) ⇒ Object
5 6 7 8 9 |
# File 'lib/uri_encoding/decoder.rb', line 5 def decode(str) encoded_chars = split_encoded_string(str) decoded_chars = encoded_chars.map{|c| decode_char(c) } decoded_chars.join end |