Class: Rapuncel::Base64String
- Defined in:
- lib/rapuncel/base_64_string.rb
Class Method Summary collapse
Instance Method Summary collapse
Methods inherited from String
Class Method Details
.decode_base64(string) ⇒ Object
20 21 22 |
# File 'lib/rapuncel/base_64_string.rb', line 20 def self.decode_base64 string new string.unpack('m')[0] end |
Instance Method Details
#base64_encoded ⇒ Object
16 17 18 |
# File 'lib/rapuncel/base_64_string.rb', line 16 def base64_encoded [self].pack 'm' end |