Class: String

Inherits:
Object
  • Object
show all
Defined in:
lib/puppet_x/icinga2/pbkdf2.rb

Overview

Class: String

Instance Method Summary collapse

Instance Method Details

#^(other) ⇒ Object

Raises:

  • (ArgumentError)


187
188
189
190
191
192
193
194
# File 'lib/puppet_x/icinga2/pbkdf2.rb', line 187

def ^(other)
  raise ArgumentError, "Can't bitwise-XOR a String with a non-String" \
    unless other.is_a? String
  raise ArgumentError, "Can't bitwise-XOR strings of different length" \
    unless self.length == other.length

  xor_impl(other)
end