Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(72)

Side by Side Diff: ppapi/native_client/src/untrusted/nacl_ppapi_util/string_buffer.h

Issue 10914053: Relocating files in the nacl repo that belong in chrome. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
(Empty)
1 /*
2 * Copyright (c) 2011 The Chromium Authors. All rights reserved.
3 * Use of this source code is governed by a BSD-style license that can be
4 * found in the LICENSE file.
5 */
6
7 #ifndef NATIVE_CLIENT_TESTS_MANIFEST_FILE_STRING_BUFFER_H_
8 #define NATIVE_CLIENT_TESTS_MANIFEST_FILE_STRING_BUFFER_H_
9
10 #include <string>
11
12 #include <stdio.h>
13 #include <stdlib.h>
14 #include <inttypes.h>
15
16 namespace nacl {
17
18 class StringBuffer {
19 public:
20 StringBuffer();
21 ~StringBuffer();
22 void DiscardOutput();
23 void Printf(char const *fmt, ...) __attribute__((format(printf, 2, 3)));
24 std::string ToString() {
25 return std::string(buffer_, insert_);
26 }
27
28 private:
29 size_t nbytes_;
30 size_t insert_;
31 char *buffer_;
32 };
33
34 } // namespace nacl
35
36 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698