pub trait Decoder { fn read_nil(&mut self); fn read_uint(&mut self) -> uint; fn read_u64(&mut self) -> u64; fn read_u32(&mut self) -> u32; fn read_u16(&mut self) -> u16; fn read_u8(&mut self) -> u8; fn read_int(&mut self) -> int; fn read_i64(&mut self) -> i64; fn read_i32(&mut self) -> i32; fn read_i16(&mut self) -> i16; fn read_i8(&mut self) -> i8; fn read_bool(&mut self) -> bool; fn read_f64(&mut self) -> f64; fn read_f32(&mut self) -> f32; fn read_float(&mut self) -> float; fn read_char(&mut self) -> char; fn read_str(&mut self) -> ~str; fn read_enum<T>(&mut self, name: &str, f: &fn(&mut Self) -> T) -> T; fn read_enum_variant<T>(&mut self, names: &[&str], f: &fn(&mut Self, uint) -> T) -> T; fn read_enum_variant_arg<T>(&mut self, a_idx: uint, f: &fn(&mut Self) -> T) -> T; fn read_enum_struct_variant<T>(&mut self, names: &[&str], f: &fn(&mut Self, uint) -> T) -> T; fn read_enum_struct_variant_field<T>(&mut self, f_name: &str, f_idx: uint, f: &fn(&mut Self) -> T) -> T; fn read_struct<T>(&mut self, s_name: &str, len: uint, f: &fn(&mut Self) -> T) -> T; fn read_struct_field<T>(&mut self, f_name: &str, f_idx: uint, f: &fn(&mut Self) -> T) -> T; fn read_tuple<T>(&mut self, f: &fn(&mut Self, uint) -> T) -> T; fn read_tuple_arg<T>(&mut self, a_idx: uint, f: &fn(&mut Self) -> T) -> T; fn read_tuple_struct<T>(&mut self, s_name: &str, f: &fn(&mut Self, uint) -> T) -> T; fn read_tuple_struct_arg<T>(&mut self, a_idx: uint, f: &fn(&mut Self) -> T) -> T; fn read_option<T>(&mut self, f: &fn(&mut Self, bool) -> T) -> T; fn read_seq<T>(&mut self, f: &fn(&mut Self, uint) -> T) -> T; fn read_seq_elt<T>(&mut self, idx: uint, f: &fn(&mut Self) -> T) -> T; fn read_map<T>(&mut self, f: &fn(&mut Self, uint) -> T) -> T; fn read_map_elt_key<T>(&mut self, idx: uint, f: &fn(&mut Self) -> T) -> T; fn read_map_elt_val<T>(&mut self, idx: uint, f: &fn(&mut Self) -> T) -> T; }
fn read_nil(&mut self)
fn read_uint(&mut self) -> uint
fn read_u64(&mut self) -> u64
fn read_u32(&mut self) -> u32
fn read_u16(&mut self) -> u16
fn read_u8(&mut self) -> u8
fn read_int(&mut self) -> int
fn read_i64(&mut self) -> i64
fn read_i32(&mut self) -> i32
fn read_i16(&mut self) -> i16
fn read_i8(&mut self) -> i8
fn read_bool(&mut self) -> bool
fn read_f64(&mut self) -> f64
fn read_f32(&mut self) -> f32
fn read_float(&mut self) -> float
fn read_char(&mut self) -> char
fn read_str(&mut self) -> ~str
fn read_enum<T>(&mut self, name: &str, f: &fn(&mut Self) -> T) -> T
fn read_enum_variant<T>(&mut self, names: &[&str], f: &fn(&mut Self, uint) -> T) -> T
fn read_enum_variant_arg<T>(&mut self, a_idx: uint, f: &fn(&mut Self) -> T) -> T
fn read_enum_struct_variant<T>(&mut self, names: &[&str], f: &fn(&mut Self, uint) -> T) -> T
fn read_enum_struct_variant_field<T>(&mut self, f_name: &str, f_idx: uint, f: &fn(&mut Self) -> T) -> T
fn read_struct<T>(&mut self, s_name: &str, len: uint, f: &fn(&mut Self) -> T) -> T
fn read_struct_field<T>(&mut self, f_name: &str, f_idx: uint, f: &fn(&mut Self) -> T) -> T
fn read_tuple<T>(&mut self, f: &fn(&mut Self, uint) -> T) -> T
fn read_tuple_arg<T>(&mut self, a_idx: uint, f: &fn(&mut Self) -> T) -> T
fn read_tuple_struct<T>(&mut self, s_name: &str, f: &fn(&mut Self, uint) -> T) -> T
fn read_tuple_struct_arg<T>(&mut self, a_idx: uint, f: &fn(&mut Self) -> T) -> T
fn read_option<T>(&mut self, f: &fn(&mut Self, bool) -> T) -> T
fn read_seq<T>(&mut self, f: &fn(&mut Self, uint) -> T) -> T
fn read_seq_elt<T>(&mut self, idx: uint, f: &fn(&mut Self) -> T) -> T
fn read_map<T>(&mut self, f: &fn(&mut Self, uint) -> T) -> T
fn read_map_elt_key<T>(&mut self, idx: uint, f: &fn(&mut Self) -> T) -> T
fn read_map_elt_val<T>(&mut self, idx: uint, f: &fn(&mut Self) -> T) -> T
Prefix searches with a type followed by a colon (e.g.
fn:
) to restrict the search to a given type.
Accepted types are: fn
, mod
,
struct
(or str
), enum
,
trait
, typedef
(or
tdef
).