Class: Ruckus::Mutator::Hibit
- Defined in:
- lib/ruckus/mutator.rb
Overview
Randomly sets the top bit of each byte, turning ASCII into hi-ASCII.
Instance Method Summary collapse
-
#initialize(opts = {}) ⇒ Hibit
constructor
A new instance of Hibit.
- #mod(x) ⇒ Object
Methods inherited from Modifier
Constructor Details
#initialize(opts = {}) ⇒ Hibit
Returns a new instance of Hibit.
241 242 243 244 245 |
# File 'lib/ruckus/mutator.rb', line 241 def initialize(opts={}) opts[:prob] ||= 50 @width = opts[:width] || 32 super end |