Aspose::Pdf::XFormCollection Class Referencefinal

Class represents collection of XFormCollection. More...

Inherits System::Collections::Generic::ICollection< System::SharedPtr< Aspose::Pdf::XForm > >.

Public Member Functions

int32_t get_Count () const
 Gets count of XForms in collection. More...
 
bool get_IsSynchronized ()
 Returns true if object is synchronized. More...
 
System::SharedPtr< System::Objectget_SyncRoot ()
 Synchronization object. More...
 
bool get_IsReadOnly () const
 Gets a value indicating whether the collection is read-only. More...
 
void Add (System::SharedPtr< XForm > const &xform)
 Adds new XForm into collection. More...
 
void Delete (int32_t index)
 Delete XForm from collectin More...
 
void Delete ()
 Deletes all XForms from collection. More...
 
void CopyTo (System::ArrayPtr< System::SharedPtr< XForm >> array, int32_t index)
 Copies XFormCollection into collection. More...
 
System::SharedPtr< System::Collections::Generic::IEnumerator< System::SharedPtr< XForm > > > GetEnumerator ()
 Retunrs collection enumerator. More...
 
void Delete (System::String name)
 Deletes XForm from collection by form name. More...
 
System::SharedPtr< XFormidx_get (int32_t index)
 Returns XForm by index. More...
 
System::SharedPtr< XFormidx_get (System::String name)
 Returns XForm by its name. Exception is thrown if XForm with specified name is not found. More...
 
void Clear ()
 Clears all items from the collection. More...
 
bool Contains (System::SharedPtr< XForm > const &item) const
 Determines whether the collection contains a specific value. More...
 
bool Remove (System::SharedPtr< XForm > const &item)
 Deletes specified item from collection. More...
 
- Public Member Functions inherited from System::Collections::Generic::ICollection< System::SharedPtr< Aspose::Pdf::XForm > >
virtual void CopyTo (System::ArrayPtr< System::SharedPtr< Aspose::Pdf::XForm > > array, int arrayIndex)=0
 
ICollectionoperator= (ICollection &&)
 
ICollectionoperator= (const ICollection &)
 
 ICollection ()
 Default constructor. More...
 
 ICollection (const ICollection &)
 Copy constructor. More...
 
 ICollection (ICollection &&)
 Move constructor. More...
 
virtual ~ICollection ()
 Destructor. 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 refernce 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 int GetHashCode () const
 Analog of C# Object.GetHashCode() method. Enables hashing of custom objects. More...
 
virtual ASPOSECPP_SHARED_API String ToString () ASPOSE_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 (unsigned int argument)
 Set n'th template argument a weak pointer (rather than shared). Allows switching pointers in containers to weak mode. More...
 
template<>
bool Equals (float const &objA, float const &objB)
 
template<>
bool Equals (double const &objA, double const &objB)
 
template<>
bool ReferenceEquals (String const &str, std::nullptr_t)
 
template<>
bool ReferenceEquals (String const &str1, String const &str2)
 

Protected Member Functions

void Add (System::String name, System::SharedPtr< Engine::Data::IPdfObject > formObj)
 
 XFormCollection (System::SharedPtr< Resources > parent, System::SharedPtr< Engine::Data::IPdfDictionary > xobject)
 XForm constructor More...
 
System::String GetFormName (System::SharedPtr< XForm > form)
 Returns name of the form in this form collection More...
 
bool HasForm (System::String formName)
 

Protected Attributes

System::WeakPtr< Resourcesparent
 

Additional Inherited Members

- Public Types inherited from System::Collections::Generic::ICollection< System::SharedPtr< Aspose::Pdf::XForm > >
typedef System::SharedPtr< Aspose::Pdf::XFormValueType
 Value type name. More...
 
typedef ICollection< System::SharedPtr< Aspose::Pdf::XForm > > ThisType
 Collection type name. More...
 
- Public Types inherited from System::Collections::Generic::IEnumerable< System::SharedPtr< Aspose::Pdf::XForm > >
typedef IEnumerator< System::SharedPtr< Aspose::Pdf::XForm > > IEnumeratorType
 Enumerator type. More...
 
- Public Types inherited from System::Object
typedef SmartPtr< Objectptr
 Alias for smart pointer type. More...
 
typedef System::Details::SharedMembersType shared_members_type
 structure to keep list of shared pointers contained in object. 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 ()
 Impleemnts C# typeof(System.Object) construct. More...
 

Detailed Description

Class represents collection of XFormCollection.

Constructor & Destructor Documentation

◆ XFormCollection()

Aspose::Pdf::XFormCollection::XFormCollection ( System::SharedPtr< Resources parent,
System::SharedPtr< Engine::Data::IPdfDictionary >  xobject 
)
protected

XForm constructor

Parameters
parentResources object which contains forms
xobjectDictionary object which contains XFormCollection

Member Function Documentation

◆ Add() [1/2]

void Aspose::Pdf::XFormCollection::Add ( System::SharedPtr< XForm > const &  xform)
virtual

Adds new XForm into collection.

Parameters
xformXForm to add into collection

Implements System::Collections::Generic::ICollection< System::SharedPtr< Aspose::Pdf::XForm > >.

◆ Add() [2/2]

void Aspose::Pdf::XFormCollection::Add ( System::String  name,
System::SharedPtr< Engine::Data::IPdfObject >  formObj 
)
protected

◆ Clear()

void Aspose::Pdf::XFormCollection::Clear ( )
virtual

◆ Contains()

bool Aspose::Pdf::XFormCollection::Contains ( System::SharedPtr< XForm > const &  item) const
virtual

Determines whether the collection contains a specific value.

Parameters
itemThe object to locate in the collection
Returns
true if item is found in the collection; otherwise, false.

Implements System::Collections::Generic::ICollection< System::SharedPtr< Aspose::Pdf::XForm > >.

◆ CopyTo()

void Aspose::Pdf::XFormCollection::CopyTo ( System::ArrayPtr< System::SharedPtr< XForm >>  array,
int32_t  index 
)

Copies XFormCollection into collection.

Parameters
arrayArray of XForm to be copied
indexIndex where XFormCollection will be copied

◆ Delete() [1/3]

void Aspose::Pdf::XFormCollection::Delete ( int32_t  index)

Delete XForm from collectin

Parameters
indexIndex of XForm which must be deleted

◆ Delete() [2/3]

void Aspose::Pdf::XFormCollection::Delete ( )

Deletes all XForms from collection.

◆ Delete() [3/3]

void Aspose::Pdf::XFormCollection::Delete ( System::String  name)

Deletes XForm from collection by form name.

Parameters
nameName of XForm to be deleted.

◆ get_Count()

int32_t Aspose::Pdf::XFormCollection::get_Count ( ) const
virtual

◆ get_IsReadOnly()

bool Aspose::Pdf::XFormCollection::get_IsReadOnly ( ) const
virtual

Gets a value indicating whether the collection is read-only.

Reimplemented from System::Collections::Generic::ICollection< System::SharedPtr< Aspose::Pdf::XForm > >.

◆ get_IsSynchronized()

bool Aspose::Pdf::XFormCollection::get_IsSynchronized ( )

Returns true if object is synchronized.

◆ get_SyncRoot()

System::SharedPtr<System::Object> Aspose::Pdf::XFormCollection::get_SyncRoot ( )

Synchronization object.

◆ GetEnumerator()

System::SharedPtr<System::Collections::Generic::IEnumerator<System::SharedPtr<XForm> > > Aspose::Pdf::XFormCollection::GetEnumerator ( )
virtual

Retunrs collection enumerator.

Returns
Enumerator for collection

Implements System::Collections::Generic::IEnumerable< System::SharedPtr< Aspose::Pdf::XForm > >.

◆ GetFormName()

System::String Aspose::Pdf::XFormCollection::GetFormName ( System::SharedPtr< XForm form)
protected

Returns name of the form in this form collection

Parameters
formForm which name is searhced
Returns
Form name in the collection; Null if form is not contained in the colleciton

◆ HasForm()

bool Aspose::Pdf::XFormCollection::HasForm ( System::String  formName)
protected

◆ idx_get() [1/2]

System::SharedPtr<XForm> Aspose::Pdf::XFormCollection::idx_get ( int32_t  index)

Returns XForm by index.

Parameters
indexIndex of XFormCollection. XForms numbering is started from 1
Returns
Retreived XForm

◆ idx_get() [2/2]

System::SharedPtr<XForm> Aspose::Pdf::XFormCollection::idx_get ( System::String  name)

Returns XForm by its name. Exception is thrown if XForm with specified name is not found.

Parameters
nameName of XForm
Returns

◆ Remove()

bool Aspose::Pdf::XFormCollection::Remove ( System::SharedPtr< XForm > const &  item)
virtual

Deletes specified item from collection.

Parameters
itemThe object to delete
Returns
true if item was deleted from collection; otherwise, false.

Implements System::Collections::Generic::ICollection< System::SharedPtr< Aspose::Pdf::XForm > >.

Member Data Documentation

◆ parent

System::WeakPtr<Resources> Aspose::Pdf::XFormCollection::parent
protected