1 // Copyright 2017 PDFium 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 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
6 
7 #ifndef FXJS_CJS_GLOBALVARIABLEARRAY_H_
8 #define FXJS_CJS_GLOBALVARIABLEARRAY_H_
9 
10 #include <memory>
11 #include <vector>
12 
13 class CJS_KeyValue;
14 
15 class CJS_GlobalVariableArray {
16  public:
17   CJS_GlobalVariableArray();
18   ~CJS_GlobalVariableArray();
19 
20   void Add(CJS_KeyValue* p);
21   int Count() const;
22   CJS_KeyValue* GetAt(int index) const;
23   void Copy(const CJS_GlobalVariableArray& array);
24 
25  private:
26   std::vector<std::unique_ptr<CJS_KeyValue>> m_Array;
27 };
28 
29 #endif  // FXJS_CJS_GLOBALVARIABLEARRAY_H_
30