Qt
Internal/Contributor docs for the Qt SDK. Note: These are NOT official API docs; those are found at https://doc.qt.io/
Loading...
Searching...
No Matches
CPDF_Array Class Referencefinal

#include <cpdf_array.h>

+ Inheritance diagram for CPDF_Array:
+ Collaboration diagram for CPDF_Array:

Public Types

using const_iterator = std::vector<RetainPtr<CPDF_Object>>::const_iterator
 
- Public Types inherited from CPDF_Object
enum  Type {
  kBoolean = 1 , kNumber , kString , kName ,
  kArray , kDictionary , kStream , kNullobj ,
  kReference
}
 

Public Member Functions

Type GetType () const override
 
RetainPtr< CPDF_ObjectClone () const override
 
CPDF_ArrayAsMutableArray () override
 
bool WriteTo (IFX_ArchiveStream *archive, const CPDF_Encryptor *encryptor) const override
 
bool IsEmpty () const
 
size_t size () const
 
RetainPtr< CPDF_ObjectGetMutableObjectAt (size_t index)
 
RetainPtr< const CPDF_ObjectGetObjectAt (size_t index) const
 
RetainPtr< CPDF_ObjectGetMutableDirectObjectAt (size_t index)
 
RetainPtr< const CPDF_ObjectGetDirectObjectAt (size_t index) const
 
ByteString GetByteStringAt (size_t index) const
 
WideString GetUnicodeTextAt (size_t index) const
 
bool GetBooleanAt (size_t index, bool bDefault) const
 
int GetIntegerAt (size_t index) const
 
float GetFloatAt (size_t index) const
 
RetainPtr< CPDF_DictionaryGetMutableDictAt (size_t index)
 
RetainPtr< const CPDF_DictionaryGetDictAt (size_t index) const
 
RetainPtr< CPDF_StreamGetMutableStreamAt (size_t index)
 
RetainPtr< const CPDF_StreamGetStreamAt (size_t index) const
 
RetainPtr< CPDF_ArrayGetMutableArrayAt (size_t index)
 
RetainPtr< const CPDF_ArrayGetArrayAt (size_t index) const
 
RetainPtr< const CPDF_NumberGetNumberAt (size_t index) const
 
RetainPtr< const CPDF_StringGetStringAt (size_t index) const
 
CFX_FloatRect GetRect () const
 
CFX_Matrix GetMatrix () const
 
absl::optional< size_t > Find (const CPDF_Object *pThat) const
 
bool Contains (const CPDF_Object *pThat) const
 
template<typename T , typename... Args>
std::enable_if<!CanInternStrings< T >::value, RetainPtr< T > >::type AppendNew (Args &&... args)
 
template<typename T , typename... Args>
std::enable_if< CanInternStrings< T >::value, RetainPtr< T > >::type AppendNew (Args &&... args)
 
template<typename T , typename... Args>
std::enable_if<!CanInternStrings< T >::value, RetainPtr< T > >::type SetNewAt (size_t index, Args &&... args)
 
template<typename T , typename... Args>
std::enable_if< CanInternStrings< T >::value, RetainPtr< T > >::type SetNewAt (size_t index, Args &&... args)
 
template<typename T , typename... Args>
std::enable_if<!CanInternStrings< T >::value, RetainPtr< T > >::type InsertNewAt (size_t index, Args &&... args)
 
template<typename T , typename... Args>
std::enable_if< CanInternStrings< T >::value, RetainPtr< T > >::type InsertNewAt (size_t index, Args &&... args)
 
void Append (RetainPtr< CPDF_Object > object)
 
void Append (RetainPtr< CPDF_Stream > stream)=delete
 
void SetAt (size_t index, RetainPtr< CPDF_Object > object)
 
void SetAt (size_t index, RetainPtr< CPDF_Stream > stream)=delete
 
void InsertAt (size_t index, RetainPtr< CPDF_Object > object)
 
void InsertAt (size_t index, RetainPtr< CPDF_Stream > stream)=delete
 
void Clear ()
 
void RemoveAt (size_t index)
 
void ConvertToIndirectObjectAt (size_t index, CPDF_IndirectObjectHolder *pHolder)
 
bool IsLocked () const
 
- Public Member Functions inherited from CPDF_Object
uint32_t GetObjNum () const
 
void SetObjNum (uint32_t objnum)
 
uint32_t GetGenNum () const
 
void SetGenNum (uint32_t gennum)
 
bool IsInline () const
 
uint64_t KeyForCache () const
 
RetainPtr< CPDF_ObjectCloneDirectObject () const
 
virtual ByteString GetString () const
 
virtual WideString GetUnicodeText () const
 
virtual float GetNumber () const
 
virtual int GetInteger () const
 
virtual void SetString (const ByteString &str)
 
virtual CPDF_BooleanAsMutableBoolean ()
 
virtual CPDF_DictionaryAsMutableDictionary ()
 
virtual CPDF_NameAsMutableName ()
 
virtual CPDF_NullAsMutableNull ()
 
virtual CPDF_NumberAsMutableNumber ()
 
virtual CPDF_ReferenceAsMutableReference ()
 
virtual CPDF_StreamAsMutableStream ()
 
virtual CPDF_StringAsMutableString ()
 
virtual RetainPtr< CPDF_ReferenceMakeReference (CPDF_IndirectObjectHolder *holder) const
 
RetainPtr< const CPDF_ObjectGetDirect () const
 
RetainPtr< CPDF_ObjectGetMutableDirect ()
 
RetainPtr< const CPDF_DictionaryGetDict () const
 
RetainPtr< CPDF_DictionaryGetMutableDict ()
 
const CPDF_ArrayAsArray () const
 
const CPDF_BooleanAsBoolean () const
 
const CPDF_DictionaryAsDictionary () const
 
const CPDF_NameAsName () const
 
const CPDF_NullAsNull () const
 
const CPDF_NumberAsNumber () const
 
const CPDF_ReferenceAsReference () const
 
const CPDF_StreamAsStream () const
 
const CPDF_StringAsString () const
 
bool IsArray () const
 
bool IsBoolean () const
 
bool IsDictionary () const
 
bool IsName () const
 
bool IsNull () const
 
bool IsNumber () const
 
bool IsReference () const
 
bool IsStream () const
 
bool IsString () const
 
- Public Member Functions inherited from fxcrt::Retainable
 Retainable ()=default
 
bool HasOneRef () const
 

Public Attributes

 CONSTRUCT_VIA_MAKE_RETAIN
 

Private Member Functions

 ~CPDF_Array () override
 
RetainPtr< CPDF_ObjectCloneNonCyclic (bool bDirect, std::set< const CPDF_Object * > *pVisited) const override
 

Friends

class CPDF_ArrayLocker
 

Additional Inherited Members

- Static Public Attributes inherited from CPDF_Object
static constexpr uint32_t kInvalidObjNum = static_cast<uint32_t>(-1)
 
- Protected Member Functions inherited from CPDF_Object
 CPDF_Object ()=default
 
 CPDF_Object (const CPDF_Object &src)=delete
 
 ~CPDF_Object () override
 
virtual const CPDF_ObjectGetDirectInternal () const
 
virtual const CPDF_DictionaryGetDictInternal () const
 
RetainPtr< CPDF_ObjectCloneObjectNonCyclic (bool bDirect) const
 
- Protected Member Functions inherited from fxcrt::Retainable
virtual ~Retainable ()=default
 
- Protected Attributes inherited from CPDF_Object
uint32_t m_ObjNum = 0
 
uint32_t m_GenNum = 0
 

Detailed Description

Definition at line 27 of file cpdf_array.h.

Member Typedef Documentation

◆ const_iterator

using CPDF_Array::const_iterator = std::vector<RetainPtr<CPDF_Object>>::const_iterator

Definition at line 29 of file cpdf_array.h.

Member Function Documentation

◆ ~CPDF_Array()

CPDF_Array::~CPDF_Array ( )
overrideprivate

Definition at line 28 of file cpdf_array.cpp.

References CPDF_Object::kInvalidObjNum, and CPDF_Object::m_ObjNum.

◆ Append() [1/2]

void CPDF_Array::Append ( RetainPtr< CPDF_Object > object)

Definition at line 225 of file cpdf_array.cpp.

◆ Append() [2/2]

void CPDF_Array::Append ( RetainPtr< CPDF_Stream > stream)
delete

◆ AppendNew() [1/2]

template<typename T , typename... Args>
std::enable_if<!CanInternStrings< T >::value, RetainPtr< T > >::type CPDF_Array::AppendNew ( Args &&... args)
inline

Definition at line 85 of file cpdf_array.h.

◆ AppendNew() [2/2]

template<typename T , typename... Args>
std::enable_if< CanInternStrings< T >::value, RetainPtr< T > >::type CPDF_Array::AppendNew ( Args &&... args)
inline

Definition at line 91 of file cpdf_array.h.

◆ AsMutableArray()

CPDF_Array * CPDF_Array::AsMutableArray ( )
overridevirtual

Reimplemented from CPDF_Object.

Definition at line 41 of file cpdf_array.cpp.

◆ Clear()

void CPDF_Array::Clear ( )

Definition at line 193 of file cpdf_array.cpp.

References IsLocked().

+ Here is the call graph for this function:

◆ Clone()

RetainPtr< CPDF_Object > CPDF_Array::Clone ( ) const
overridevirtual

Implements CPDF_Object.

Definition at line 45 of file cpdf_array.cpp.

References CPDF_Object::CloneObjectNonCyclic().

+ Here is the call graph for this function:

◆ CloneNonCyclic()

RetainPtr< CPDF_Object > CPDF_Array::CloneNonCyclic ( bool bDirect,
std::set< const CPDF_Object * > * pVisited ) const
overrideprivatevirtual

Reimplemented from CPDF_Object.

Definition at line 49 of file cpdf_array.cpp.

◆ Contains()

bool CPDF_Array::Contains ( const CPDF_Object * pThat) const

Definition at line 92 of file cpdf_array.cpp.

◆ ConvertToIndirectObjectAt()

void CPDF_Array::ConvertToIndirectObjectAt ( size_t index,
CPDF_IndirectObjectHolder * pHolder )

Definition at line 204 of file cpdf_array.cpp.

References IsLocked().

+ Here is the call graph for this function:

◆ Find()

absl::optional< size_t > CPDF_Array::Find ( const CPDF_Object * pThat) const

Definition at line 84 of file cpdf_array.cpp.

◆ GetArrayAt()

RetainPtr< const CPDF_Array > CPDF_Array::GetArrayAt ( size_t index) const

Definition at line 181 of file cpdf_array.cpp.

◆ GetBooleanAt()

bool CPDF_Array::GetBooleanAt ( size_t index,
bool bDefault ) const

Definition at line 133 of file cpdf_array.cpp.

References CPDF_Object::GetInteger(), and ToBoolean().

+ Here is the call graph for this function:

◆ GetByteStringAt()

ByteString CPDF_Array::GetByteStringAt ( size_t index) const

Definition at line 121 of file cpdf_array.cpp.

References fxcrt::ByteString::ByteString().

+ Here is the call graph for this function:

◆ GetDictAt()

RetainPtr< const CPDF_Dictionary > CPDF_Array::GetDictAt ( size_t index) const

Definition at line 165 of file cpdf_array.cpp.

◆ GetDirectObjectAt()

RetainPtr< const CPDF_Object > CPDF_Array::GetDirectObjectAt ( size_t index) const

Definition at line 112 of file cpdf_array.cpp.

◆ GetFloatAt()

float CPDF_Array::GetFloatAt ( size_t index) const

Definition at line 146 of file cpdf_array.cpp.

◆ GetIntegerAt()

int CPDF_Array::GetIntegerAt ( size_t index) const

Definition at line 140 of file cpdf_array.cpp.

◆ GetMatrix()

CFX_Matrix CPDF_Array::GetMatrix ( ) const

Definition at line 76 of file cpdf_array.cpp.

References CFX_Matrix::CFX_Matrix().

Referenced by CPDF_Dictionary::GetMatrixFor().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ GetMutableArrayAt()

RetainPtr< CPDF_Array > CPDF_Array::GetMutableArrayAt ( size_t index)

Definition at line 177 of file cpdf_array.cpp.

◆ GetMutableDictAt()

RetainPtr< CPDF_Dictionary > CPDF_Array::GetMutableDictAt ( size_t index)

Definition at line 152 of file cpdf_array.cpp.

References CPDF_Object::GetMutableDict().

+ Here is the call graph for this function:

◆ GetMutableDirectObjectAt()

RetainPtr< CPDF_Object > CPDF_Array::GetMutableDirectObjectAt ( size_t index)

Definition at line 116 of file cpdf_array.cpp.

◆ GetMutableObjectAt()

RetainPtr< CPDF_Object > CPDF_Array::GetMutableObjectAt ( size_t index)

Definition at line 104 of file cpdf_array.cpp.

◆ GetMutableStreamAt()

RetainPtr< CPDF_Stream > CPDF_Array::GetMutableStreamAt ( size_t index)

Definition at line 169 of file cpdf_array.cpp.

◆ GetNumberAt()

RetainPtr< const CPDF_Number > CPDF_Array::GetNumberAt ( size_t index) const

Definition at line 185 of file cpdf_array.cpp.

◆ GetObjectAt()

RetainPtr< const CPDF_Object > CPDF_Array::GetObjectAt ( size_t index) const

Definition at line 108 of file cpdf_array.cpp.

◆ GetRect()

CFX_FloatRect CPDF_Array::GetRect ( ) const

Definition at line 64 of file cpdf_array.cpp.

Referenced by CPDF_Dictionary::GetRectFor().

+ Here is the caller graph for this function:

◆ GetStreamAt()

RetainPtr< const CPDF_Stream > CPDF_Array::GetStreamAt ( size_t index) const

Definition at line 173 of file cpdf_array.cpp.

◆ GetStringAt()

RetainPtr< const CPDF_String > CPDF_Array::GetStringAt ( size_t index) const

Definition at line 189 of file cpdf_array.cpp.

◆ GetType()

CPDF_Object::Type CPDF_Array::GetType ( ) const
overridevirtual

Implements CPDF_Object.

Definition at line 37 of file cpdf_array.cpp.

References CPDF_Object::kArray.

◆ GetUnicodeTextAt()

WideString CPDF_Array::GetUnicodeTextAt ( size_t index) const

Definition at line 127 of file cpdf_array.cpp.

References fxcrt::WideString::WideString().

+ Here is the call graph for this function:

◆ InsertAt() [1/2]

void CPDF_Array::InsertAt ( size_t index,
RetainPtr< CPDF_Object > object )

Definition at line 221 of file cpdf_array.cpp.

◆ InsertAt() [2/2]

void CPDF_Array::InsertAt ( size_t index,
RetainPtr< CPDF_Stream > stream )
delete

◆ InsertNewAt() [1/2]

template<typename T , typename... Args>
std::enable_if<!CanInternStrings< T >::value, RetainPtr< T > >::type CPDF_Array::InsertNewAt ( size_t index,
Args &&... args )
inline

Definition at line 109 of file cpdf_array.h.

◆ InsertNewAt() [2/2]

template<typename T , typename... Args>
std::enable_if< CanInternStrings< T >::value, RetainPtr< T > >::type CPDF_Array::InsertNewAt ( size_t index,
Args &&... args )
inline

Definition at line 115 of file cpdf_array.h.

◆ IsEmpty()

bool CPDF_Array::IsEmpty ( ) const
inline

Definition at line 40 of file cpdf_array.h.

Referenced by CPDF_ColorSpace::Load().

+ Here is the caller graph for this function:

◆ IsLocked()

bool CPDF_Array::IsLocked ( ) const
inline

Definition at line 141 of file cpdf_array.h.

Referenced by Clear(), ConvertToIndirectObjectAt(), and RemoveAt().

+ Here is the caller graph for this function:

◆ RemoveAt()

void CPDF_Array::RemoveAt ( size_t index)

Definition at line 198 of file cpdf_array.cpp.

References IsLocked().

+ Here is the call graph for this function:

◆ SetAt() [1/2]

void CPDF_Array::SetAt ( size_t index,
RetainPtr< CPDF_Object > object )

Definition at line 217 of file cpdf_array.cpp.

◆ SetAt() [2/2]

void CPDF_Array::SetAt ( size_t index,
RetainPtr< CPDF_Stream > stream )
delete

◆ SetNewAt() [1/2]

template<typename T , typename... Args>
std::enable_if<!CanInternStrings< T >::value, RetainPtr< T > >::type CPDF_Array::SetNewAt ( size_t index,
Args &&... args )
inline

Definition at line 97 of file cpdf_array.h.

◆ SetNewAt() [2/2]

template<typename T , typename... Args>
std::enable_if< CanInternStrings< T >::value, RetainPtr< T > >::type CPDF_Array::SetNewAt ( size_t index,
Args &&... args )
inline

Definition at line 103 of file cpdf_array.h.

◆ size()

size_t CPDF_Array::size ( ) const
inline

Definition at line 41 of file cpdf_array.h.

◆ WriteTo()

bool CPDF_Array::WriteTo ( IFX_ArchiveStream * archive,
const CPDF_Encryptor * encryptor ) const
overridevirtual

Implements CPDF_Object.

Definition at line 264 of file cpdf_array.cpp.

References IFX_WriteStream::WriteString().

+ Here is the call graph for this function:

Friends And Related Symbol Documentation

◆ CPDF_ArrayLocker

friend class CPDF_ArrayLocker
friend

Definition at line 144 of file cpdf_array.h.

Member Data Documentation

◆ CONSTRUCT_VIA_MAKE_RETAIN

CPDF_Array::CONSTRUCT_VIA_MAKE_RETAIN

Definition at line 31 of file cpdf_array.h.


The documentation for this class was generated from the following files: