Making fields in std and extra : private #4386
This commit is contained in:
parent
dadb6f0cd9
commit
0ada7c7ffe
113 changed files with 1499 additions and 445 deletions
|
@ -48,12 +48,13 @@ pub type Object = TreeMap<~str, Json>;
|
|||
/// If an error occurs while parsing some JSON, this is the structure which is
|
||||
/// returned
|
||||
pub struct Error {
|
||||
// all were made privv by reedlepee
|
||||
/// The line number at which the error occurred
|
||||
line: uint,
|
||||
priv line: uint,
|
||||
/// The column number at which the error occurred
|
||||
col: uint,
|
||||
priv col: uint,
|
||||
/// A message describing the type of the error
|
||||
msg: @~str,
|
||||
priv msg: @~str,
|
||||
}
|
||||
|
||||
fn escape_str(s: &str) -> ~str {
|
||||
|
@ -86,6 +87,7 @@ fn spaces(n: uint) -> ~str {
|
|||
|
||||
/// A structure for implementing serialization to JSON.
|
||||
pub struct Encoder {
|
||||
// all were already priv
|
||||
priv wr: @io::Writer,
|
||||
}
|
||||
|
||||
|
@ -243,6 +245,7 @@ impl serialize::Encoder for Encoder {
|
|||
/// Another encoder for JSON, but prints out human-readable JSON instead of
|
||||
/// compact data
|
||||
pub struct PrettyEncoder {
|
||||
// all were already priv
|
||||
priv wr: @io::Writer,
|
||||
priv indent: uint,
|
||||
}
|
||||
|
@ -479,6 +482,7 @@ impl Json{
|
|||
}
|
||||
|
||||
pub struct Parser<T> {
|
||||
// all were already priv
|
||||
priv rdr: ~T,
|
||||
priv ch: char,
|
||||
priv line: uint,
|
||||
|
@ -868,6 +872,7 @@ pub fn from_str(s: &str) -> Result<Json, Error> {
|
|||
|
||||
/// A structure to decode JSON to values in rust.
|
||||
pub struct Decoder {
|
||||
// all were already priv
|
||||
priv stack: ~[Json],
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue