Pepper_56_C++_interfaces
Pepper_56_C++_interfaces
 All Classes Namespaces Files Functions Typedefs Enumerations Macros Groups
var_array.h
Go to the documentation of this file.
1 // Copyright 2013 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 #ifndef PPAPI_CPP_VAR_ARRAY_H_
6 #define PPAPI_CPP_VAR_ARRAY_H_
7 
8 #include "ppapi/c/pp_bool.h"
9 #include "ppapi/c/pp_stdint.h"
10 #include "ppapi/cpp/var.h"
11 
14 
15 namespace pp {
16 
17 class VarArray : public Var {
18  public:
20  VarArray();
21 
27  explicit VarArray(const Var& var);
28 
33  explicit VarArray(const PP_Var& var);
34 
36  VarArray(const VarArray& other);
37 
38  virtual ~VarArray();
39 
41  VarArray& operator=(const VarArray& other);
42 
49  virtual Var& operator=(const Var& other);
50 
57  Var Get(uint32_t index) const;
58 
69  bool Set(uint32_t index, const Var& value);
70 
74  uint32_t GetLength() const;
75 
85  bool SetLength(uint32_t length);
86 };
87 
88 } // namespace pp
89 
90 #endif // PPAPI_CPP_VAR_ARRAY_H_
uint32_t GetLength() const
bool Set(uint32_t index, const Var &value)
VarArray()
Constructs a new array var.
bool SetLength(uint32_t length)
VarArray & operator=(const VarArray &other)
Assignment operator.
A generic type used for passing data types between the module and the page.
Definition: var.h:23
Var Get(uint32_t index) const
Definition: var_array.h:17