Home
last modified time | relevance | path

Searched refs:FX_FILESIZE (Results 1 – 25 of 52) sorted by relevance

123

/external/pdfium/core/fpdfapi/parser/
Dcpdf_syntax_parser.h39 FX_FILESIZE GetPos() const { return m_Pos; } in GetPos()
40 void SetPos(FX_FILESIZE pos) { m_Pos = std::min(pos, m_FileLen); } in SetPos()
52 bool BackwardsSearchToWord(const ByteStringView& word, FX_FILESIZE limit);
53 FX_FILESIZE FindTag(const ByteStringView& tag, FX_FILESIZE limit);
55 bool GetCharAt(FX_FILESIZE pos, uint8_t& ch);
74 bool ReadBlockAt(FX_FILESIZE read_pos);
76 bool GetCharAtBackward(FX_FILESIZE pos, uint8_t* ch);
78 bool IsWholeWord(FX_FILESIZE startpos,
79 FX_FILESIZE limit,
85 unsigned int ReadEOLMarkers(FX_FILESIZE pos);
[all …]
Dcpdf_linearized_header.h26 FX_FILESIZE GetFileSize() const { return m_szFileSize; } in GetFileSize()
29 FX_FILESIZE GetMainXRefTableFirstEntryOffset() const { in GetMainXRefTableFirstEntryOffset()
34 FX_FILESIZE GetFirstPageEndOffset() const { return m_szFirstPageEndOffset; } in GetFirstPageEndOffset()
38 FX_FILESIZE GetLastXRefOffset() const { return m_szLastXRefOffset; } in GetLastXRefOffset()
42 FX_FILESIZE GetHintStart() const { return m_szHintStart; } in GetHintStart()
47 FX_FILESIZE szLastXRefOffset);
50 const FX_FILESIZE m_szFileSize;
52 const FX_FILESIZE m_szMainXRefTableFirstEntryOffset;
54 const FX_FILESIZE m_szFirstPageEndOffset;
56 const FX_FILESIZE m_szLastXRefOffset;
[all …]
Dcpdf_parser.h67 FX_FILESIZE GetLastXRefOffset() const { return m_LastXRefOffset; } in GetLastXRefOffset()
82 FX_FILESIZE GetObjectPositionOrZero(uint32_t objnum) const;
91 FX_FILESIZE GetObjectOffset(uint32_t objnum) const;
98 FX_FILESIZE pos,
103 FX_FILESIZE pos,
105 FX_FILESIZE* pResultPos);
123 FX_FILESIZE pos;
124 FX_FILESIZE archive_obj_num;
133 bool LoadCrossRefV4(FX_FILESIZE pos, bool bSkip);
164 FX_FILESIZE ParseStartXRef();
[all …]
Dcpdf_read_validator.cpp14 constexpr FX_FILESIZE kAlignBlockValue = CPDF_ModuleMgr::kFileBufSize;
16 FX_FILESIZE AlignDown(FX_FILESIZE offset) { in AlignDown()
20 FX_FILESIZE AlignUp(FX_FILESIZE offset) { in AlignUp()
61 FX_FILESIZE offset, in ReadBlock()
81 FX_FILESIZE CPDF_ReadValidator::GetSize() { in GetSize()
85 void CPDF_ReadValidator::ScheduleDownload(FX_FILESIZE offset, size_t size) { in ScheduleDownload()
90 const FX_FILESIZE start_segment_offset = AlignDown(offset); in ScheduleDownload()
109 bool CPDF_ReadValidator::IsDataRangeAvailable(FX_FILESIZE offset, in IsDataRangeAvailable()
126 FX_FILESIZE offset, in CheckDataRangeAndRequestIfUnavailable()
140 file_size_, static_cast<FX_FILESIZE>(end_segment_offset.ValueOrDie())); in CheckDataRangeAndRequestIfUnavailable()
Dcpdf_syntax_parser.cpp52 bool CPDF_SyntaxParser::GetCharAt(FX_FILESIZE pos, uint8_t& ch) { in GetCharAt()
53 AutoRestorer<FX_FILESIZE> save_pos(&m_Pos); in GetCharAt()
58 bool CPDF_SyntaxParser::ReadBlockAt(FX_FILESIZE read_pos) { in ReadBlockAt()
78 FX_FILESIZE pos = m_Pos + m_HeaderOffset; in GetNextChar()
90 bool CPDF_SyntaxParser::GetCharAtBackward(FX_FILESIZE pos, uint8_t* ch) { in GetCharAtBackward()
96 FX_FILESIZE block_start = 0; in GetCharAtBackward()
348 AutoRestorer<FX_FILESIZE> save_pos(&m_Pos); in PeekNextWord()
372 FX_FILESIZE SavedObjPos = m_Pos; in GetObjectBodyInternal()
379 FX_FILESIZE SavedPos = m_Pos; in GetObjectBodyInternal()
431 FX_FILESIZE SavedPos = m_Pos - key.GetLength(); in GetObjectBodyInternal()
[all …]
Dcpdf_cross_ref_avail.h20 FX_FILESIZE last_crossref_offset);
23 FX_FILESIZE last_crossref_offset() const { return last_crossref_offset_; } in last_crossref_offset()
42 void AddCrossRefForCheck(FX_FILESIZE crossref_offset);
47 const FX_FILESIZE last_crossref_offset_ = 0;
51 FX_FILESIZE current_offset_ = 0;
52 std::queue<FX_FILESIZE> cross_refs_for_check_;
53 std::set<FX_FILESIZE> registered_crossrefs_;
Dcpdf_cross_ref_avail_unittest.cpp42 const FX_FILESIZE last_crossref_offset = 0; in TEST()
59 const FX_FILESIZE last_crossref_offset = 0; in TEST()
77 const FX_FILESIZE last_crossref_offset = 70000; in TEST()
94 const FX_FILESIZE last_crossref_offset = 0; in TEST()
116 const FX_FILESIZE last_crossref_offset = 0; in TEST()
128 const FX_FILESIZE last_crossref_offset = 0; in TEST()
180 const FX_FILESIZE last_crossref_offset = cur_offset; in TEST()
228 const FX_FILESIZE last_crossref_offset = cur_offset; in TEST()
278 const FX_FILESIZE last_crossref_offset = last_v4_table_offset; in TEST()
293 const FX_FILESIZE last_crossref_offset = 0; in TEST()
[all …]
Dcpdf_read_validator_unittest.cpp20 std::pair<FX_FILESIZE, FX_FILESIZE> MakeRange(uint32_t start, uint32_t end) { in MakeRange()
21 return std::pair<FX_FILESIZE, FX_FILESIZE>(start, end); in MakeRange()
29 bool IsDataAvail(FX_FILESIZE offset, size_t size) override { in IsDataAvail()
31 available_range_.second >= static_cast<FX_FILESIZE>(offset + size); in IsDataAvail()
34 void SetAvailableRange(const std::pair<FX_FILESIZE, FX_FILESIZE>& range) { in SetAvailableRange() argument
43 std::pair<FX_FILESIZE, FX_FILESIZE> available_range_;
51 void AddSegment(FX_FILESIZE offset, size_t size) override { in AddSegment()
56 const std::pair<FX_FILESIZE, FX_FILESIZE>& GetLastRequstedRange() const { in GetLastRequstedRange()
63 std::pair<FX_FILESIZE, FX_FILESIZE> last_requested_range_;
161 std::numeric_limits<FX_FILESIZE>::max() - 1, in TEST()
Dcpdf_parser.cpp38 constexpr FX_FILESIZE kPDFHeaderSize = 9;
144 FX_FILESIZE CPDF_Parser::GetObjectPositionOrZero(uint32_t objnum) const { in GetObjectPositionOrZero()
304 FX_FILESIZE CPDF_Parser::ParseStartXRef() { in ParseStartXRef()
364 FX_FILESIZE CPDF_Parser::GetObjectOffset(uint32_t objnum) const { in GetObjectOffset()
372 FX_FILESIZE pos = GetObjectPositionOrZero(objnum); in GetObjectOffset()
387 FX_FILESIZE SavedPos = m_pSyntax->GetPos(); in VerifyCrossRefV4()
403 bool CPDF_Parser::LoadAllCrossRefV4(FX_FILESIZE xrefpos) { in LoadAllCrossRefV4()
416 std::vector<FX_FILESIZE> CrossRefList; in LoadAllCrossRefV4()
417 std::vector<FX_FILESIZE> XRefStreamList; in LoadAllCrossRefV4()
418 std::set<FX_FILESIZE> seen_xrefpos; in LoadAllCrossRefV4()
[all …]
Dcpdf_hint_tables.h28 FX_FILESIZE* szPageStartPos,
29 FX_FILESIZE* szPageLength,
50 const std::vector<FX_FILESIZE>& szArray) const;
59 FX_FILESIZE m_szFirstPageObjOffset;
64 std::vector<FX_FILESIZE> m_szPageOffsetArray;
65 std::vector<FX_FILESIZE> m_szSharedObjOffsetArray;
Dcpdf_read_validator.h42 bool CheckDataRangeAndRequestIfUnavailable(FX_FILESIZE offset, size_t size);
46 bool ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override;
47 FX_FILESIZE GetSize() override;
55 void ScheduleDownload(FX_FILESIZE offset, size_t size);
56 bool IsDataRangeAvailable(FX_FILESIZE offset, size_t size) const;
66 const FX_FILESIZE file_size_;
Dcpdf_cross_ref_avail.cpp30 FX_FILESIZE last_crossref_offset) in CPDF_CrossRefAvail()
156 pdfium::base::IsValueInRangeForNumericType<FX_FILESIZE>(xrefpos)) in CheckCrossRefV4Trailer()
157 AddCrossRefForCheck(static_cast<FX_FILESIZE>(xrefpos)); in CheckCrossRefV4Trailer()
162 pdfium::base::IsValueInRangeForNumericType<FX_FILESIZE>( in CheckCrossRefV4Trailer()
164 AddCrossRefForCheck(static_cast<FX_FILESIZE>(stream_xref_offset)); in CheckCrossRefV4Trailer()
193 pdfium::base::IsValueInRangeForNumericType<FX_FILESIZE>(xrefpos)) in CheckCrossRefStream()
194 AddCrossRefForCheck(static_cast<FX_FILESIZE>(xrefpos)); in CheckCrossRefStream()
201 void CPDF_CrossRefAvail::AddCrossRefForCheck(FX_FILESIZE crossref_offset) { in AddCrossRefForCheck()
Dcpdf_linearized_header.cpp21 constexpr FX_FILESIZE kLinearizedHeaderOffset = 9;
41 FX_FILESIZE file_size) { in IsLinearizedHeaderValid()
64 !IsValidNumericDictionaryValue<FX_FILESIZE>(pDict.get(), "L", 1) || in Parse()
66 !IsValidNumericDictionaryValue<FX_FILESIZE>(pDict.get(), "T", 1) || in Parse()
68 !IsValidNumericDictionaryValue<FX_FILESIZE>(pDict.get(), "E", 1) || in Parse()
88 FX_FILESIZE szLastXRefOffset) in CPDF_LinearizedHeader()
/external/pdfium/core/fxcrt/
Dcfx_fileaccess_windows.cpp96 FX_FILESIZE CFX_FileAccess_Windows::GetSize() const { in GetSize()
104 return (FX_FILESIZE)size.QuadPart; in GetSize()
107 FX_FILESIZE CFX_FileAccess_Windows::GetPosition() const { in GetPosition()
109 return (FX_FILESIZE)-1; in GetPosition()
114 return (FX_FILESIZE)-1; in GetPosition()
116 return (FX_FILESIZE)newPos.QuadPart; in GetPosition()
119 FX_FILESIZE CFX_FileAccess_Windows::SetPosition(FX_FILESIZE pos) { in SetPosition()
121 return (FX_FILESIZE)-1; in SetPosition()
127 return (FX_FILESIZE)-1; in SetPosition()
129 return (FX_FILESIZE)newPos.QuadPart; in SetPosition()
[all …]
Dcfx_fileaccess_posix.cpp80 FX_FILESIZE CFX_FileAccess_Posix::GetSize() const { in GetSize()
89 FX_FILESIZE CFX_FileAccess_Posix::GetPosition() const { in GetPosition()
91 return (FX_FILESIZE)-1; in GetPosition()
95 FX_FILESIZE CFX_FileAccess_Posix::SetPosition(FX_FILESIZE pos) { in SetPosition()
97 return (FX_FILESIZE)-1; in SetPosition()
115 FX_FILESIZE pos) { in ReadPos()
122 if (SetPosition(pos) == (FX_FILESIZE)-1) { in ReadPos()
129 FX_FILESIZE pos) { in WritePos()
133 if (SetPosition(pos) == (FX_FILESIZE)-1) { in WritePos()
146 bool CFX_FileAccess_Posix::Truncate(FX_FILESIZE szFile) { in Truncate()
Dfx_stream.h48 virtual FX_FILESIZE CurrentOffset() const = 0;
54 virtual FX_FILESIZE GetPosition() = 0;
63 virtual FX_FILESIZE GetSize() = 0;
66 FX_FILESIZE offset,
77 FX_FILESIZE GetPosition() override;
80 virtual bool ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) = 0;
81 virtual FX_FILESIZE GetSize() = 0;
96 FX_FILESIZE GetPosition() override = 0;
98 bool ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override = 0;
99 FX_FILESIZE GetSize() override = 0;
[all …]
Difx_fileaccess.h25 virtual FX_FILESIZE GetSize() const = 0;
26 virtual FX_FILESIZE GetPosition() const = 0;
27 virtual FX_FILESIZE SetPosition(FX_FILESIZE pos) = 0;
30 virtual size_t ReadPos(void* pBuffer, size_t szBuffer, FX_FILESIZE pos) = 0;
33 FX_FILESIZE pos) = 0;
35 virtual bool Truncate(FX_FILESIZE szFile) = 0;
Dcfx_fileaccess_windows.h22 FX_FILESIZE GetSize() const override;
23 FX_FILESIZE GetPosition() const override;
24 FX_FILESIZE SetPosition(FX_FILESIZE pos) override;
27 size_t ReadPos(void* pBuffer, size_t szBuffer, FX_FILESIZE pos) override;
30 FX_FILESIZE pos) override;
32 bool Truncate(FX_FILESIZE szFile) override;
Dcfx_fileaccess_posix.h24 FX_FILESIZE GetSize() const override;
25 FX_FILESIZE GetPosition() const override;
26 FX_FILESIZE SetPosition(FX_FILESIZE pos) override;
29 size_t ReadPos(void* pBuffer, size_t szBuffer, FX_FILESIZE pos) override;
32 FX_FILESIZE pos) override;
34 bool Truncate(FX_FILESIZE szFile) override;
Dcfx_seekablestreamproxy.cpp174 Seek(From::Begin, static_cast<FX_FILESIZE>(m_wBOMLength)); in CFX_SeekableStreamProxy()
184 void CFX_SeekableStreamProxy::Seek(From eSeek, FX_FILESIZE iOffset) { in Seek()
190 pdfium::base::CheckedNumeric<FX_FILESIZE> new_pos = m_iPosition; in Seek()
193 new_pos.ValueOrDefault(std::numeric_limits<FX_FILESIZE>::max()); in Seek()
197 pdfium::clamp(m_iPosition, static_cast<FX_FILESIZE>(0), GetLength()); in Seek()
220 pdfium::base::CheckedNumeric<FX_FILESIZE> new_pos = m_iPosition; in ReadData()
247 FX_FILESIZE pos = GetPosition(); in ReadString()
281 pdfium::base::CheckedNumeric<FX_FILESIZE> new_pos = m_iPosition; in WriteString()
283 m_iPosition = new_pos.ValueOrDefault(std::numeric_limits<FX_FILESIZE>::max()); in WriteString()
285 pdfium::clamp(m_iPosition, static_cast<FX_FILESIZE>(0), GetLength()); in WriteString()
Dcfx_memorystream.cpp44 FX_FILESIZE CFX_MemoryStream::GetSize() { in GetSize()
45 return static_cast<FX_FILESIZE>(m_nCurSize); in GetSize()
52 FX_FILESIZE CFX_MemoryStream::GetPosition() { in GetPosition()
53 return static_cast<FX_FILESIZE>(m_nCurPos); in GetPosition()
61 FX_FILESIZE offset, in ReadBlock()
80 offset -= static_cast<FX_FILESIZE>(nStartBlock * m_nGrowSize); in ReadBlock()
104 FX_FILESIZE offset, in WriteBlock()
139 offset -= static_cast<FX_FILESIZE>(nStartBlock * m_nGrowSize); in WriteBlock()
Dcfx_seekablemultistream.cpp25 FX_FILESIZE CFX_SeekableMultiStream::GetSize() { in GetSize()
33 FX_FILESIZE offset, in ReadBlock()
39 FX_FILESIZE dwSize = acc->GetSize(); in ReadBlock()
67 FX_FILESIZE CFX_SeekableMultiStream::GetPosition() { in GetPosition()
81 FX_FILESIZE offset, in WriteBlock()
/external/pdfium/core/fxcrt/xml/
Dcxml_parser.cpp112 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in SkipWhiteSpaces()
121 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in SkipWhiteSpaces()
128 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in GetName()
146 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in GetName()
154 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in SkipLiterals()
169 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in SkipLiterals()
178 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwBufferSize); in SkipLiterals()
184 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in GetCharRef()
261 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in GetCharRef()
270 m_nOffset = m_nBufferOffset + static_cast<FX_FILESIZE>(m_dwIndex); in GetAttrValue()
[all …]
Dcfx_xmlsyntaxparser.h48 FX_FILESIZE GetCurrentPos() const { return m_ParsedChars + m_Start; } in GetCurrentPos()
49 FX_FILESIZE GetCurrentBinaryPos() const;
105 FX_FILESIZE m_iCurrentPos;
109 FX_FILESIZE m_ParsedChars;
113 FX_FILESIZE m_Start; // Start position in m_Buffer
114 FX_FILESIZE m_End; // End position in m_Buffer
/external/pdfium/testing/
Dfx_string_testhelpers.h22 bool ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override { in ReadBlock()
25 FX_FILESIZE GetSize() override { return data_size_; } in GetSize()
28 explicit CFX_InvalidSeekableReadStream(FX_FILESIZE data_size) in CFX_InvalidSeekableReadStream()
31 FX_FILESIZE data_size_;
40 bool ReadBlock(void* buffer, FX_FILESIZE offset, size_t size) override { in ReadBlock()
53 FX_FILESIZE GetSize() override { in GetSize()
54 return static_cast<FX_FILESIZE>(data_size_); in GetSize()

123