Home | History | Annotate | Download | only in base

Lines Matching refs:Pickle

22 class Pickle;
24 // PickleIterator reads data from a Pickle. The Pickle object must remain valid
29 explicit PickleIterator(const Pickle& pickle);
31 // Methods for reading the payload of the Pickle. To read from the start of
32 // the Pickle, create a PickleIterator from a Pickle. If successful, these
79 // Read Type from Pickle.
100 const char* payload_; // Start of our pickle's payload.
109 // The Pickle class supports appending primitive values (ints, strings, etc.)
110 // to a pickle instance. The Pickle instance grows its internal memory buffer
112 // buffer is exposed as the "data" of the Pickle. This "data" can be passed
113 // to a Pickle object to initialize it for reading.
115 // When reading from a Pickle object, it is important for the consumer to know
116 // what value types to read and in what order to read them as the Pickle does
119 // The Pickle's data has a header which contains the size of the Pickle's
121 // space is controlled by the header_size parameter passed to the Pickle
124 class BASE_EXPORT Pickle {
126 // Initialize a Pickle object using the default header size.
127 Pickle();
129 // Initialize a Pickle object with the specified header size in bytes, which
130 // must be greater-than-or-equal-to sizeof(Pickle::Header). The header size
132 explicit Pickle(int header_size);
134 // Initializes a Pickle from a const block of data. The data is not copied;
135 // instead the data is merely referenced by this Pickle. Only const methods
136 // should be used on the Pickle when initialized this way. The header
138 Pickle(const char* data, int data_len);
140 // Initializes a Pickle as a deep copy of another Pickle.
141 Pickle(const Pickle& other);
148 virtual ~Pickle();
151 Pickle& operator=(const Pickle& other);
153 // Returns the number of bytes written in the Pickle, including the header.
156 // Returns the data for this Pickle.
159 // Returns the effective memory capacity of this Pickle, that is, the total
161 // read-only Pickle. This should be used only for diagnostic / profiling
165 // Methods for adding to the payload of the Pickle. These values are
166 // appended to the end of the Pickle's payload. When reading values from a
167 // Pickle, it is important to read them in the order in which they were added
168 // to the Pickle.
221 // to the Pickle constructor.
233 // The payload is the pickle data immediately following the header.
264 // pickle by |num_bytes|. Claimed memory, including padding, is zeroed.
270 // if the entire Pickle is not found in the given data range.
275 // Parse pickle header and return total size of the pickle. Data range
276 // doesn't need to contain entire pickle.
277 // Returns true if pickle header was found and parsed. Callers must check
280 // overflow during pickle size calculation, it sets |pickle_size| to the