Module: Datadog::Core::Utils::Base64
- Defined in:
- lib/datadog/core/utils/base64.rb
Overview
Helper methods for encoding and decoding base64
Class Method Summary collapse
Class Method Details
.encode64(bin) ⇒ Object
8 9 10 |
# File 'lib/datadog/core/utils/base64.rb', line 8 def self.encode64(bin) [bin].pack('m') end |
.strict_decode64(str) ⇒ Object
16 17 18 |
# File 'lib/datadog/core/utils/base64.rb', line 16 def self.strict_decode64(str) str.unpack1('m0') end |
.strict_encode64(bin) ⇒ Object
12 13 14 |
# File 'lib/datadog/core/utils/base64.rb', line 12 def self.strict_encode64(bin) [bin].pack('m0') end |