| Module | BCodec |
| In: |
lib/bcodec.rb
lib/bcodec/encode.rb lib/bcodec/decode.rb |
bcodec - Ruby library to decode/encode bencoded data Copyright (C) 2006,2007 Thomas <tochiro+bcodecNO@SPAMrubyforge.org>
This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
You should have received a copy of the GNU General Public License along with this program. If not, see <www.gnu.org/licenses/>.
Decodes bencoded data from an IO-like object (IO, File, StringIO or similar)
Returns the decoded object which is either of these: Array, Integer (Fixnum or Bignum), Hash or String