Class represent XForm More...

#include "XForm.h"

Inherits System::IDisposable, Aspose::Pdf::ISupportsMemoryCleanup, and Aspose::Pdf::IOperatorContainer.

Public Member Functions

ASPOSE_PDF_SHARED_API System::SharedPtr< Aspose::Pdf::Rectangleget_BBox ()
 Gets form bounding box. More...
 
ASPOSE_PDF_SHARED_API void set_BBox (System::SharedPtr< Aspose::Pdf::Rectangle > value)
 Sets form bounding box. More...
 
ASPOSE_PDF_SHARED_API System::String get_Name ()
 Gets form name. Form name is name which used to reference form in XObejct ductionary in page resources. More...
 
ASPOSE_PDF_SHARED_API void set_Name (System::String value)
 Sets form name. Form name is name which used to reference form in XObejct ductionary in page resources. More...
 
ASPOSE_PDF_SHARED_API System::String get_IT ()
 Gets form IT. Form IT is a name describing the intent of the XObject. More...
 
ASPOSE_PDF_SHARED_API System::String get_Subtype ()
 Gets form Subtype. More...
 
ASPOSE_PDF_SHARED_API System::SharedPtr< OperatorCollectionget_Contents () override
 Gets operators of the form. More...
 
ASPOSE_PDF_SHARED_API System::SharedPtr< Aspose::Pdf::Opiget_Opi ()
 Gets The Open Prepress Interface (OPI). More...
 
ASPOSE_PDF_SHARED_API System::SharedPtr< Aspose::Pdf::Matrixget_Matrix ()
 Gets matrix of the form. More...
 
ASPOSE_PDF_SHARED_API void set_Matrix (System::SharedPtr< Aspose::Pdf::Matrix > value)
 Sets matrix of the form. More...
 
ASPOSE_PDF_SHARED_API System::SharedPtr< Aspose::Pdf::Resourcesget_Resources () override
 Gets Form XObject resources. More...
 
ASPOSE_PDF_SHARED_API System::SharedPtr< Aspose::Pdf::Rectangleget_Rectangle ()
 Gets rectangel of the form. More...
 
ASPOSE_PDF_SHARED_API System::SharedPtr< Aspose::Pdf::ResourcesGetResources (bool allowCreate)
 Returns resources of Form X-Object More...
 
ASPOSE_PDF_SHARED_API System::SharedPtr< Aspose::Pdf::ResourcesGetResources ()
 Returns resources of Form X-Object. If For does not have resources and allowCreate is true, Resources will be automatically created for the form. More...
 
ASPOSE_PDF_SHARED_API void Dispose () override
 Frees up memory More...
 
ASPOSE_PDF_SHARED_API void FreeMemory () override
 Clears cached data More...
 
- Public Member Functions inherited from System::Object
ASPOSECPP_SHARED_API Object ()
 Creates object. Initializes all internal data structures. More...
 
virtual ASPOSECPP_SHARED_API ~Object ()
 Destroys object. Frees all internal data structures. More...
 
ASPOSECPP_SHARED_API Object (Object const &x)
 Copy constructor. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More...
 
Objectoperator= (Object const &x)
 Assignment operator. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More...
 
ObjectSharedRefAdded ()
 Increments shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
int SharedRefRemovedSafe ()
 Decrements and returns shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
int RemovedSharedRefs (int count)
 Decreases shared reference count by specified value. More...
 
Detail::SmartPtrCounter * WeakRefAdded ()
 Increments weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
void WeakRefRemoved ()
 Decrements weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More...
 
Detail::SmartPtrCounter * GetCounter ()
 Gets reference counter data structure associated with the object. More...
 
int SharedCount () const
 Gets current value of shared reference counter. More...
 
ASPOSECPP_SHARED_API void Lock ()
 Implements C# lock() statement locking. Call directly or use LockContext sentry object. More...
 
ASPOSECPP_SHARED_API void Unlock ()
 Implements C# lock() statement unlocking. Call directly or use LockContext sentry object. More...
 
virtual ASPOSECPP_SHARED_API bool Equals (ptr obj)
 Compares objects using C# Object.Equals semantics. More...
 
virtual ASPOSECPP_SHARED_API int32_t GetHashCode () const
 Analog of C# Object.GetHashCode() method. Enables hashing of custom objects. More...
 
virtual ASPOSECPP_SHARED_API String ToString () const
 Analog of C# Object.ToString() method. Enables converting custom objects to string. More...
 
virtual ASPOSECPP_SHARED_API ptr MemberwiseClone () const
 Analog of C# Object.MemberwiseClone() method. Enables cloning custom types. More...
 
virtual ASPOSECPP_SHARED_API const TypeInfoGetType () const
 Gets actual type of object. Analog of C# System.Object.GetType() call. More...
 
virtual ASPOSECPP_SHARED_API bool Is (const TypeInfo &targetType) const
 Check if object represents an instance of type described by targetType. Analog of C# 'is' operator. More...
 
virtual ASPOSECPP_SHARED_API void SetTemplateWeakPtr (uint32_t argument)
 Set n'th template argument a weak pointer (rather than shared). Allows switching pointers in containers to weak mode. More...
 
virtual ASPOSECPP_SHARED_API bool FastCast (const Details::FastRttiBase &helper, void **out_ptr) const
 For internal purposes only. More...
 
template<>
bool Equals (float const &objA, float const &objB)
 Emulates C#-style floating point comparison where two NaNs are considered equal even though according to IEC 60559:1989 NaN is not equal to any value, including NaN. More...
 
template<>
bool Equals (double const &objA, double const &objB)
 Emulates C#-style floating point comparison where two NaNs are considered equal even though according to IEC 60559:1989 NaN is not equal to any value, including NaN. More...
 
template<>
bool ReferenceEquals (String const &str, std::nullptr_t)
 Specialization of Object::ReferenceEquals for case of string and nullptr. More...
 
template<>
bool ReferenceEquals (String const &str1, String const &str2)
 Specialization of Object::ReferenceEquals for case of strings. More...
 

Static Public Member Functions

static ASPOSE_PDF_SHARED_API System::SharedPtr< XFormCreateNewForm (System::SharedPtr< Page > source, System::SharedPtr< Document > document)
 Creates XForm which duplicates contents of the page. More...
 
- Static Public Member Functions inherited from System::Object
static bool ReferenceEquals (ptr const &objA, ptr const &objB)
 Compares objects by reference. More...
 
template<typename T >
static std::enable_if<!IsSmartPtr< T >::value, bool >::type ReferenceEquals (T const &objA, T const &objB)
 Compares objects by reference. More...
 
template<typename T >
static std::enable_if<!IsSmartPtr< T >::value, bool >::type ReferenceEquals (T const &objA, std::nullptr_t)
 Reference-compares value type object with nullptr. More...
 
template<typename T1 , typename T2 >
static std::enable_if< IsSmartPtr< T1 >::value &&IsSmartPtr< T2 >::value, bool >::type Equals (T1 const &objA, T2 const &objB)
 Compares reference type objects in C# style. More...
 
template<typename T1 , typename T2 >
static std::enable_if<!IsSmartPtr< T1 >::value &&!IsSmartPtr< T2 >::value, bool >::type Equals (T1 const &objA, T2 const &objB)
 Compares value type objects in C# style. More...
 
static const TypeInfoType ()
 Implements C# typeof(System.Object) construct. More...
 

Protected Member Functions

 XForm (System::SharedPtr< Engine::Data::IPdfObject > xform)
 Constructor of XForm.Constructs XForm on base of Pdf.Kit.Engine PDf object. More...
 
 MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION (XForm, CODEPORTING_ARGS(System::SharedPtr< Engine::Data::IPdfObject > xform))
 
 XForm (System::SharedPtr< Engine::Data::IPdfObject > xform, bool isPattern)
 
 MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION (XForm, CODEPORTING_ARGS(System::SharedPtr< Engine::Data::IPdfObject > xform, bool isPattern))
 
bool ContainsOwnResources ()
 
void setResources (System::SharedPtr< Engine::Data::IPdfPrimitive > resources)
 Change resources entry for x-form. More...
 
System::ArrayPtr< double > GetRectangle ()
 
System::SharedPtr< Aspose::Pdf::RectangleGetRectangleOfText ()
 Returns rectangle occupied by text of XForm. More...
 
System::SharedPtr< System::Collections::Generic::List< System::SharedPtr< System::Object > > > FindReferecnes (System::String name)
 
void ReleaseResources ()
 
virtual ASPOSE_PDF_SHARED_API ~XForm ()
 

Static Protected Member Functions

static System::SharedPtr< XFormCreateNewForm (System::SharedPtr< Engine::Data::ITrailerable > trailerable)
 Creates new XForm in the document. More...
 
static System::SharedPtr< XFormCreateNewForm_OLD (System::SharedPtr< Page > source, System::SharedPtr< Engine::Data::ITrailerable > trailerable, System::SharedPtr< Copier > copier)
 
static System::SharedPtr< XFormCreateNewForm (System::SharedPtr< Page > source, System::SharedPtr< Engine::Data::ITrailerable > trailerable, System::SharedPtr< Copier > copier)
 
static System::SharedPtr< XFormCreateNewForm (System::SharedPtr< Page > source, System::SharedPtr< Engine::Data::ITrailerable > trailerable)
 

Protected Attributes

System::SharedPtr< Aspose::Pdf::Resourcesresources
 
System::WeakPtr< Document_document
 
System::SharedPtr< Engine::Data::IPdfObject > EngineObj
 Pdf.Kit.Engine obejct decribes form More...
 

Additional Inherited Members

- Public Types inherited from System::Object
typedef SmartPtr< Objectptr
 Alias for smart pointer type. More...
 

Detailed Description

Class represent XForm

Constructor & Destructor Documentation

◆ XForm() [1/2]

Aspose::Pdf::XForm::XForm ( System::SharedPtr< Engine::Data::IPdfObject >  xform)
protected

Constructor of XForm.Constructs XForm on base of Pdf.Kit.Engine PDf object.

Parameters
xform

◆ XForm() [2/2]

Aspose::Pdf::XForm::XForm ( System::SharedPtr< Engine::Data::IPdfObject >  xform,
bool  isPattern 
)
protected

◆ ~XForm()

virtual ASPOSE_PDF_SHARED_API Aspose::Pdf::XForm::~XForm ( )
protectedvirtual

Member Function Documentation

◆ ContainsOwnResources()

bool Aspose::Pdf::XForm::ContainsOwnResources ( )
protected

◆ CreateNewForm() [1/4]

static ASPOSE_PDF_SHARED_API System::SharedPtr<XForm> Aspose::Pdf::XForm::CreateNewForm ( System::SharedPtr< Page source,
System::SharedPtr< Document document 
)
static

Creates XForm which duplicates contents of the page.

Parameters
sourceSource page
documentDocument where new XForm will be added.
Returns
Newly created XForm.

◆ CreateNewForm() [2/4]

static System::SharedPtr<XForm> Aspose::Pdf::XForm::CreateNewForm ( System::SharedPtr< Engine::Data::ITrailerable >  trailerable)
staticprotected

Creates new XForm in the document.

Parameters
trailerableDescribes ITrailerable object
Returns
Newly created XForm

◆ CreateNewForm() [3/4]

static System::SharedPtr<XForm> Aspose::Pdf::XForm::CreateNewForm ( System::SharedPtr< Page source,
System::SharedPtr< Engine::Data::ITrailerable >  trailerable,
System::SharedPtr< Copier >  copier 
)
staticprotected

◆ CreateNewForm() [4/4]

static System::SharedPtr<XForm> Aspose::Pdf::XForm::CreateNewForm ( System::SharedPtr< Page source,
System::SharedPtr< Engine::Data::ITrailerable >  trailerable 
)
staticprotected

◆ CreateNewForm_OLD()

static System::SharedPtr<XForm> Aspose::Pdf::XForm::CreateNewForm_OLD ( System::SharedPtr< Page source,
System::SharedPtr< Engine::Data::ITrailerable >  trailerable,
System::SharedPtr< Copier >  copier 
)
staticprotected

◆ Dispose()

ASPOSE_PDF_SHARED_API void Aspose::Pdf::XForm::Dispose ( )
overridevirtual

Frees up memory

Reimplemented from System::IDisposable.

◆ FindReferecnes()

System::SharedPtr<System::Collections::Generic::List<System::SharedPtr<System::Object> > > Aspose::Pdf::XForm::FindReferecnes ( System::String  name)
protected

◆ FreeMemory()

ASPOSE_PDF_SHARED_API void Aspose::Pdf::XForm::FreeMemory ( )
overridevirtual

Clears cached data

Implements Aspose::Pdf::ISupportsMemoryCleanup.

◆ get_BBox()

ASPOSE_PDF_SHARED_API System::SharedPtr<Aspose::Pdf::Rectangle> Aspose::Pdf::XForm::get_BBox ( )

Gets form bounding box.

◆ get_Contents()

ASPOSE_PDF_SHARED_API System::SharedPtr<OperatorCollection> Aspose::Pdf::XForm::get_Contents ( )
overridevirtual

Gets operators of the form.

Implements Aspose::Pdf::IOperatorContainer.

◆ get_IT()

ASPOSE_PDF_SHARED_API System::String Aspose::Pdf::XForm::get_IT ( )

Gets form IT. Form IT is a name describing the intent of the XObject.

◆ get_Matrix()

ASPOSE_PDF_SHARED_API System::SharedPtr<Aspose::Pdf::Matrix> Aspose::Pdf::XForm::get_Matrix ( )

Gets matrix of the form.

◆ get_Name()

ASPOSE_PDF_SHARED_API System::String Aspose::Pdf::XForm::get_Name ( )

Gets form name. Form name is name which used to reference form in XObejct ductionary in page resources.

◆ get_Opi()

ASPOSE_PDF_SHARED_API System::SharedPtr<Aspose::Pdf::Opi> Aspose::Pdf::XForm::get_Opi ( )

Gets The Open Prepress Interface (OPI).

◆ get_Rectangle()

ASPOSE_PDF_SHARED_API System::SharedPtr<Aspose::Pdf::Rectangle> Aspose::Pdf::XForm::get_Rectangle ( )

Gets rectangel of the form.

◆ get_Resources()

ASPOSE_PDF_SHARED_API System::SharedPtr<Aspose::Pdf::Resources> Aspose::Pdf::XForm::get_Resources ( )
overridevirtual

Gets Form XObject resources.

Implements Aspose::Pdf::IOperatorContainer.

◆ get_Subtype()

ASPOSE_PDF_SHARED_API System::String Aspose::Pdf::XForm::get_Subtype ( )

Gets form Subtype.

◆ GetRectangle()

System::ArrayPtr<double> Aspose::Pdf::XForm::GetRectangle ( )
protected

◆ GetRectangleOfText()

System::SharedPtr<Aspose::Pdf::Rectangle> Aspose::Pdf::XForm::GetRectangleOfText ( )
protected

Returns rectangle occupied by text of XForm.

Returns
X-Form object rectangle

◆ GetResources() [1/2]

ASPOSE_PDF_SHARED_API System::SharedPtr<Aspose::Pdf::Resources> Aspose::Pdf::XForm::GetResources ( bool  allowCreate)

Returns resources of Form X-Object

Parameters
allowCreateIf For does not have resources and allowCreate is true, Resources will be automatically created for the form.
Returns
Resources.

◆ GetResources() [2/2]

ASPOSE_PDF_SHARED_API System::SharedPtr<Aspose::Pdf::Resources> Aspose::Pdf::XForm::GetResources ( )

Returns resources of Form X-Object. If For does not have resources and allowCreate is true, Resources will be automatically created for the form.

Returns
Resources object

◆ MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION() [1/2]

Aspose::Pdf::XForm::MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION ( XForm  ,
CODEPORTING_ARGS(System::SharedPtr< Engine::Data::IPdfObject > xform)   
)
protected

◆ MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION() [2/2]

Aspose::Pdf::XForm::MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION ( XForm  ,
CODEPORTING_ARGS(System::SharedPtr< Engine::Data::IPdfObject > xform, bool isPattern)   
)
protected

◆ ReleaseResources()

void Aspose::Pdf::XForm::ReleaseResources ( )
protected

◆ set_BBox()

ASPOSE_PDF_SHARED_API void Aspose::Pdf::XForm::set_BBox ( System::SharedPtr< Aspose::Pdf::Rectangle value)

Sets form bounding box.

◆ set_Matrix()

ASPOSE_PDF_SHARED_API void Aspose::Pdf::XForm::set_Matrix ( System::SharedPtr< Aspose::Pdf::Matrix value)

Sets matrix of the form.

◆ set_Name()

ASPOSE_PDF_SHARED_API void Aspose::Pdf::XForm::set_Name ( System::String  value)

Sets form name. Form name is name which used to reference form in XObejct ductionary in page resources.

◆ setResources()

void Aspose::Pdf::XForm::setResources ( System::SharedPtr< Engine::Data::IPdfPrimitive >  resources)
protected

Change resources entry for x-form.

Parameters
resources

Member Data Documentation

◆ _document

System::WeakPtr<Document> Aspose::Pdf::XForm::_document
protected

◆ EngineObj

System::SharedPtr<Engine::Data::IPdfObject> Aspose::Pdf::XForm::EngineObj
protected

Pdf.Kit.Engine obejct decribes form

◆ resources

System::SharedPtr<Aspose::Pdf::Resources> Aspose::Pdf::XForm::resources
protected