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

Side by Side Diff: components/nacl/renderer/plugin/srpc_params.h

Issue 1569283002: NaCl cleanup: Remove SrpcParams and SrpcClient, which are unused now (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Created 4 years, 11 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
OLDNEW
(Empty)
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 // Parameter types for SRPC Invocation.
6
7 #ifndef COMPONENTS_NACL_RENDERER_PLUGIN_SRPC_PARAMS_H
8 #define COMPONENTS_NACL_RENDERER_PLUGIN_SRPC_PARAMS_H
9
10 #include "base/macros.h"
11 #include "native_client/src/include/nacl_macros.h"
12 #include "native_client/src/include/portability_string.h"
13 #include "native_client/src/shared/srpc/nacl_srpc.h"
14
15 namespace plugin {
16
17 // A utility class that builds and deletes parameter vectors used in rpcs.
18 class SrpcParams {
19 public:
20 SrpcParams() {
21 memset(ins_, 0, sizeof(ins_));
22 memset(outs_, 0, sizeof(outs_));
23 }
24
25 ~SrpcParams() {
26 FreeAll();
27 }
28
29 bool Init(const char* in_types, const char* out_types);
30
31 NaClSrpcArg** ins() const { return const_cast<NaClSrpcArg**>(ins_); }
32 NaClSrpcArg** outs() const { return const_cast<NaClSrpcArg**>(outs_); }
33
34 private:
35 NACL_DISALLOW_COPY_AND_ASSIGN(SrpcParams);
36 void FreeAll();
37 // The ins_ and outs_ arrays contain one more element, to hold a NULL pointer
38 // to indicate the end of the list.
39 NaClSrpcArg* ins_[NACL_SRPC_MAX_ARGS + 1];
40 NaClSrpcArg* outs_[NACL_SRPC_MAX_ARGS + 1];
41 };
42
43 } // namespace plugin
44
45 #endif // COMPONENTS_NACL_RENDERER_PLUGIN_SRPC_PARAMS_H
OLDNEW
« no previous file with comments | « components/nacl/renderer/plugin/srpc_client.cc ('k') | components/nacl/renderer/plugin/srpc_params.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698