| OLD | NEW |
| 1 // Copyright 2016 PDFium Authors. All rights reserved. | 1 // Copyright 2016 PDFium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com | 5 // Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com |
| 6 | 6 |
| 7 #ifndef CORE_FPDFAPI_PARSER_CPDF_INDIRECT_OBJECT_HOLDER_H_ | 7 #ifndef CORE_FPDFAPI_PARSER_CPDF_INDIRECT_OBJECT_HOLDER_H_ |
| 8 #define CORE_FPDFAPI_PARSER_CPDF_INDIRECT_OBJECT_HOLDER_H_ | 8 #define CORE_FPDFAPI_PARSER_CPDF_INDIRECT_OBJECT_HOLDER_H_ |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 21 matching lines...) Expand all Loading... |
| 32 uint32_t objnum, | 32 uint32_t objnum, |
| 33 std::unique_ptr<CPDF_Object> pObj); | 33 std::unique_ptr<CPDF_Object> pObj); |
| 34 | 34 |
| 35 uint32_t GetLastObjNum() const { return m_LastObjNum; } | 35 uint32_t GetLastObjNum() const { return m_LastObjNum; } |
| 36 void SetLastObjNum(uint32_t objnum) { m_LastObjNum = objnum; } | 36 void SetLastObjNum(uint32_t objnum) { m_LastObjNum = objnum; } |
| 37 | 37 |
| 38 const_iterator begin() const { return m_IndirectObjs.begin(); } | 38 const_iterator begin() const { return m_IndirectObjs.begin(); } |
| 39 const_iterator end() const { return m_IndirectObjs.end(); } | 39 const_iterator end() const { return m_IndirectObjs.end(); } |
| 40 | 40 |
| 41 protected: | 41 protected: |
| 42 virtual CPDF_Object* ParseIndirectObject(uint32_t objnum); | 42 virtual std::unique_ptr<CPDF_Object> ParseIndirectObject(uint32_t objnum); |
| 43 | 43 |
| 44 private: | 44 private: |
| 45 uint32_t m_LastObjNum; | 45 uint32_t m_LastObjNum; |
| 46 std::map<uint32_t, std::unique_ptr<CPDF_Object>> m_IndirectObjs; | 46 std::map<uint32_t, std::unique_ptr<CPDF_Object>> m_IndirectObjs; |
| 47 }; | 47 }; |
| 48 | 48 |
| 49 #endif // CORE_FPDFAPI_PARSER_CPDF_INDIRECT_OBJECT_HOLDER_H_ | 49 #endif // CORE_FPDFAPI_PARSER_CPDF_INDIRECT_OBJECT_HOLDER_H_ |
| OLD | NEW |