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

Side by Side Diff: core/include/fpdfapi/cpdf_parser.h

Issue 1782673002: Split off IPDF_CryptoHandler into its own .cpp/.h files (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Move virtual dtor to .cpp file. Created 4 years, 9 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
« no previous file with comments | « BUILD.gn ('k') | core/include/fpdfapi/fpdf_parser.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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_INCLUDE_FPDFAPI_CPDF_PARSER_H_ 7 #ifndef CORE_INCLUDE_FPDFAPI_CPDF_PARSER_H_
8 #define CORE_INCLUDE_FPDFAPI_CPDF_PARSER_H_ 8 #define CORE_INCLUDE_FPDFAPI_CPDF_PARSER_H_
9 9
10 #include <map> 10 #include <map>
11 #include <memory> 11 #include <memory>
12 #include <set> 12 #include <set>
13 13
14 #include "core/include/fxcrt/fx_basic.h" 14 #include "core/include/fxcrt/fx_basic.h"
15 15
16 class CPDF_Array; 16 class CPDF_Array;
17 class CPDF_CryptoHandler;
18 class CPDF_Dictionary; 17 class CPDF_Dictionary;
19 class CPDF_Document; 18 class CPDF_Document;
20 class CPDF_IndirectObjectHolder; 19 class CPDF_IndirectObjectHolder;
21 class CPDF_Object; 20 class CPDF_Object;
22 class CPDF_StreamAcc; 21 class CPDF_StreamAcc;
23 class CPDF_SyntaxParser; 22 class CPDF_SyntaxParser;
24 class IFX_FileRead; 23 class IFX_FileRead;
24 class IPDF_CryptoHandler;
25 class IPDF_SecurityHandler; 25 class IPDF_SecurityHandler;
26 26
27 class CPDF_Parser { 27 class CPDF_Parser {
28 public: 28 public:
29 enum Error { 29 enum Error {
30 SUCCESS = 0, 30 SUCCESS = 0,
31 FILE_ERROR, 31 FILE_ERROR,
32 FORMAT_ERROR, 32 FORMAT_ERROR,
33 PASSWORD_ERROR, 33 PASSWORD_ERROR,
34 HANDLER_ERROR 34 HANDLER_ERROR
(...skipping 21 matching lines...) Expand all
56 FX_DWORD objnum); 56 FX_DWORD objnum);
57 57
58 FX_DWORD GetLastObjNum() const; 58 FX_DWORD GetLastObjNum() const;
59 bool IsValidObjectNumber(FX_DWORD objnum) const; 59 bool IsValidObjectNumber(FX_DWORD objnum) const;
60 FX_FILESIZE GetObjectPositionOrZero(FX_DWORD objnum) const; 60 FX_FILESIZE GetObjectPositionOrZero(FX_DWORD objnum) const;
61 uint8_t GetObjectType(FX_DWORD objnum) const; 61 uint8_t GetObjectType(FX_DWORD objnum) const;
62 uint16_t GetObjectGenNum(FX_DWORD objnum) const; 62 uint16_t GetObjectGenNum(FX_DWORD objnum) const;
63 bool IsVersionUpdated() const { return m_bVersionUpdated; } 63 bool IsVersionUpdated() const { return m_bVersionUpdated; }
64 bool IsObjectFreeOrNull(FX_DWORD objnum) const; 64 bool IsObjectFreeOrNull(FX_DWORD objnum) const;
65 FX_BOOL IsFormStream(FX_DWORD objnum, FX_BOOL& bForm); 65 FX_BOOL IsFormStream(FX_DWORD objnum, FX_BOOL& bForm);
66 CPDF_CryptoHandler* GetCryptoHandler(); 66 IPDF_CryptoHandler* GetCryptoHandler();
67 IFX_FileRead* GetFileAccess() const; 67 IFX_FileRead* GetFileAccess() const;
68 68
69 FX_FILESIZE GetObjectOffset(FX_DWORD objnum) const; 69 FX_FILESIZE GetObjectOffset(FX_DWORD objnum) const;
70 FX_FILESIZE GetObjectSize(FX_DWORD objnum) const; 70 FX_FILESIZE GetObjectSize(FX_DWORD objnum) const;
71 71
72 void GetIndirectBinary(FX_DWORD objnum, uint8_t*& pBuffer, FX_DWORD& size); 72 void GetIndirectBinary(FX_DWORD objnum, uint8_t*& pBuffer, FX_DWORD& size);
73 int GetFileVersion() const { return m_FileVersion; } 73 int GetFileVersion() const { return m_FileVersion; }
74 FX_BOOL IsXRefStream() const { return m_bXRefStream; } 74 FX_BOOL IsXRefStream() const { return m_bXRefStream; }
75 75
76 CPDF_Object* ParseIndirectObjectAt(CPDF_IndirectObjectHolder* pObjList, 76 CPDF_Object* ParseIndirectObjectAt(CPDF_IndirectObjectHolder* pObjList,
(...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after
164 kPostObjNum, 164 kPostObjNum,
165 kGenNum, 165 kGenNum,
166 kPostGenNum, 166 kPostGenNum,
167 kTrailer, 167 kTrailer,
168 kBeginObj, 168 kBeginObj,
169 kEndObj 169 kEndObj
170 }; 170 };
171 }; 171 };
172 172
173 #endif // CORE_INCLUDE_FPDFAPI_CPDF_PARSER_H_ 173 #endif // CORE_INCLUDE_FPDFAPI_CPDF_PARSER_H_
OLDNEW
« no previous file with comments | « BUILD.gn ('k') | core/include/fpdfapi/fpdf_parser.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698