simple_bencode 0.1.4

Simple bencode encoder and decoder, that uses neither rustc-serialize or Serde. Instead, it serializes from / deserializes to a tree using a 4-branch enum.
Documentation
1
2
3
4
5
6
7
8
9
10
use std::collections::HashMap;

/// The possible value types in a bencode object.
#[derive(Debug, PartialEq, Eq)]
pub enum Value {
    String(Vec<u8>),
    Integer(i64),
    List(Vec<Value>),
    Dictionary(HashMap<Vec<u8>, Value>),
}