Class: Ragel::Bitmap::Array16
- Inherits:
-
Object
- Object
- Ragel::Bitmap::Array16
- Defined in:
- lib/ragel/bitmap.rb
Instance Method Summary collapse
- #[](idx) ⇒ Object
-
#initialize(highstring, lowstring) ⇒ Array16
constructor
A new instance of Array16.
Constructor Details
#initialize(highstring, lowstring) ⇒ Array16
Returns a new instance of Array16.
27 28 29 30 |
# File 'lib/ragel/bitmap.rb', line 27 def initialize(highstring, lowstring) @highstring = highstring @lowstring = lowstring end |
Instance Method Details
#[](idx) ⇒ Object
32 33 34 |
# File 'lib/ragel/bitmap.rb', line 32 def [](idx) (@highstring.getbyte(idx) << 8) | @lowstring.getbyte(idx) end |