Aspose::Pdf::Annotations::AnnotationSelector Class Referencefinal

This class is used for selecting annotations using Visitor template idea. More...

Inherits Aspose::Pdf::Annotations::IAnnotationVisitor.

Public Member Functions

System::SharedPtr< System::Collections::Generic::IList< System::SharedPtr< Annotation > > > get_Selected ()
 The list of selected objects. More...
 
 AnnotationSelector ()
 Initializes new instance of the AnnotationSelector class. More...
 
void Visit (System::SharedPtr< LinkAnnotation > link)
 Select link annotation if AnnotationSelector was initialized with LinkAnnotation object. More...
 
 AnnotationSelector (System::SharedPtr< Annotation > annotation)
 Initializes new AnnotationSelector object. More...
 
void Visit (System::SharedPtr< FileAttachmentAnnotation > attachment)
 Select attachment annotation if AnnotationSelector was initialized with FileAttachmentAnnotation object. More...
 
void Visit (System::SharedPtr< TextAnnotation > text)
 Select text annotation if AnnotationSelector was initialized with TextAnnotation object. More...
 
void Visit (System::SharedPtr< RedactionAnnotation > redact)
 Select redact annotation if AnnotationSelector was initialized with RedactAnnotation object. More...
 
void Visit (System::SharedPtr< FreeTextAnnotation > freetext)
 Select freetext annotation if AnnotationSelector was initialized with FreeTextAnnotation object. More...
 
void Visit (System::SharedPtr< HighlightAnnotation > highlight)
 Select attachment annotation if AnnotationSelector was initialized with FreeTextAnnotation object. More...
 
void Visit (System::SharedPtr< UnderlineAnnotation > underline)
 Select underline annotation if AnnotationSelector was initialized with UnderlineAnnotation object. More...
 
void Visit (System::SharedPtr< StrikeOutAnnotation > strikeOut)
 Select strikeOut annotation if AnnotationSelector was initialized with StrikeOutAnnotation object. More...
 
void Visit (System::SharedPtr< SquigglyAnnotation > squiggly)
 Select squiggly annotation if AnnotationSelector was initialized with SquigglyAnnotation object. More...
 
void Visit (System::SharedPtr< PopupAnnotation > popup)
 Select popup annotation if AnnotationSelector was initialized with PopupAnnotation object. More...
 
void Visit (System::SharedPtr< LineAnnotation > line)
 Select line annotation if AnnotationSelector was initialized with LineAnnotation object. More...
 
void Visit (System::SharedPtr< CircleAnnotation > circle)
 Select circle annotation if AnnotationSelector was initialized with CircleAnnotation object. More...
 
void Visit (System::SharedPtr< SquareAnnotation > square)
 Select square annotation if AnnotationSelector was initialized with SquareAnnotation object. More...
 
void Visit (System::SharedPtr< InkAnnotation > ink)
 Select ink annotation if AnnotationSelector was initialized with InkAnnotation object. More...
 
void Visit (System::SharedPtr< PolylineAnnotation > polyline)
 Select polyline annotation if AnnotationSelector was initialized with PolylineAnnotation object. More...
 
void Visit (System::SharedPtr< PolygonAnnotation > polygon)
 Select polygon annotation if AnnotationSelector was initialized with PolygonAnnotation object. More...
 
void Visit (System::SharedPtr< CaretAnnotation > caret)
 Select caret annotation if AnnotationSelector was initialized with CaretAnnotation object. More...
 
void Visit (System::SharedPtr< StampAnnotation > stamp)
 Select stamp annotation if AnnotationSelector was initialized with StampAnnotation object. More...
 
void Visit (System::SharedPtr< WidgetAnnotation > widget)
 Select widget annotation if AnnotationSelector was initialized with WidgetAnnotation object. More...
 
void Visit (System::SharedPtr< WatermarkAnnotation > watermark)
 Select watermark annotation if AnnotationSelector was initialized with WatermarkAnnotation object. More...
 
void Visit (System::SharedPtr< MovieAnnotation > movie)
 Select movie annotation if AnnotationSelector was initialized with MovieAnnotation object. More...
 
void Visit (System::SharedPtr< RichMediaAnnotation > richMedia)
 Select movie annotation if AnnotationSelector was initialized with RichMedia annotation object. More...
 
void Visit (System::SharedPtr< ScreenAnnotation > screen)
 Select screen annotation if AnnotationSelector was initialized with ScreenAnnotation object. More...
 
void Visit (System::SharedPtr< PDF3DAnnotation > pdf3D)
 Select PDF3D annotation if AnnotationSelector was initialized with PDF3DAnnotation object. 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 Attributes

System::SharedPtr< System::Collections::Generic::List< System::SharedPtr< Annotation > > > selected
 
System::SharedPtr< Annotationannotation
 

Additional Inherited Members

- 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

This class is used for selecting annotations using Visitor template idea.

Constructor & Destructor Documentation

◆ AnnotationSelector() [1/2]

Aspose::Pdf::Annotations::AnnotationSelector::AnnotationSelector ( )

Initializes new instance of the AnnotationSelector class.

◆ AnnotationSelector() [2/2]

Aspose::Pdf::Annotations::AnnotationSelector::AnnotationSelector ( System::SharedPtr< Annotation annotation)

Initializes new AnnotationSelector object.

Parameters
annotationAnnotation to be selected. This object only describes some characteristics we want found annotations to have, e.g. the type of annotation.

Member Function Documentation

◆ get_Selected()

System::SharedPtr<System::Collections::Generic::IList<System::SharedPtr<Annotation> > > Aspose::Pdf::Annotations::AnnotationSelector::get_Selected ( )

The list of selected objects.

◆ Visit() [1/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< LinkAnnotation link)
virtual

Select link annotation if AnnotationSelector was initialized with LinkAnnotation object.

Parameters
linkLinkAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [2/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< FileAttachmentAnnotation attachment)
virtual

Select attachment annotation if AnnotationSelector was initialized with FileAttachmentAnnotation object.

Parameters
attachmentFileAttachmentAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [3/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< TextAnnotation text)
virtual

Select text annotation if AnnotationSelector was initialized with TextAnnotation object.

Parameters
textTextAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [4/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< RedactionAnnotation redact)

Select redact annotation if AnnotationSelector was initialized with RedactAnnotation object.

Parameters
redactRedactAnnotation object for selecting.

◆ Visit() [5/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< FreeTextAnnotation freetext)
virtual

Select freetext annotation if AnnotationSelector was initialized with FreeTextAnnotation object.

Parameters
freetextFreeTextAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [6/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< HighlightAnnotation highlight)
virtual

Select attachment annotation if AnnotationSelector was initialized with FreeTextAnnotation object.

Parameters
highlightHighlightAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [7/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< UnderlineAnnotation underline)
virtual

Select underline annotation if AnnotationSelector was initialized with UnderlineAnnotation object.

Parameters
underlineUnderlineAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [8/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< StrikeOutAnnotation strikeOut)
virtual

Select strikeOut annotation if AnnotationSelector was initialized with StrikeOutAnnotation object.

Parameters
strikeOutStrikeOutAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [9/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< SquigglyAnnotation squiggly)
virtual

Select squiggly annotation if AnnotationSelector was initialized with SquigglyAnnotation object.

Parameters
squigglySquigglyAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [10/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< PopupAnnotation popup)
virtual

Select popup annotation if AnnotationSelector was initialized with PopupAnnotation object.

Parameters
popupPopupAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [11/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< LineAnnotation line)
virtual

Select line annotation if AnnotationSelector was initialized with LineAnnotation object.

Parameters
lineLineAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [12/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< CircleAnnotation circle)
virtual

Select circle annotation if AnnotationSelector was initialized with CircleAnnotation object.

Parameters
circleCircleAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [13/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< SquareAnnotation square)
virtual

Select square annotation if AnnotationSelector was initialized with SquareAnnotation object.

Parameters
squareSquareAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [14/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< InkAnnotation ink)
virtual

Select ink annotation if AnnotationSelector was initialized with InkAnnotation object.

Parameters
inkInkAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [15/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< PolylineAnnotation polyline)
virtual

Select polyline annotation if AnnotationSelector was initialized with PolylineAnnotation object.

Parameters
polylinePolylineAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [16/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< PolygonAnnotation polygon)
virtual

Select polygon annotation if AnnotationSelector was initialized with PolygonAnnotation object.

Parameters
polygonPolygonAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [17/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< CaretAnnotation caret)
virtual

Select caret annotation if AnnotationSelector was initialized with CaretAnnotation object.

Parameters
caretCaretAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [18/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< StampAnnotation stamp)
virtual

Select stamp annotation if AnnotationSelector was initialized with StampAnnotation object.

Parameters
stampStampAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [19/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< WidgetAnnotation widget)
virtual

Select widget annotation if AnnotationSelector was initialized with WidgetAnnotation object.

Parameters
widgetWidgetAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [20/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< WatermarkAnnotation watermark)

Select watermark annotation if AnnotationSelector was initialized with WatermarkAnnotation object.

Parameters
watermarkWatermarkAnnotation for selecting.

◆ Visit() [21/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< MovieAnnotation movie)
virtual

Select movie annotation if AnnotationSelector was initialized with MovieAnnotation object.

Parameters
movieMovieAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [22/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< RichMediaAnnotation richMedia)

Select movie annotation if AnnotationSelector was initialized with RichMedia annotation object.

Parameters
richMediaRichMedia annotation.

◆ Visit() [23/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< ScreenAnnotation screen)
virtual

Select screen annotation if AnnotationSelector was initialized with ScreenAnnotation object.

Parameters
screenScreenAnnotation object for selecting.

Implements Aspose::Pdf::Annotations::IAnnotationVisitor.

◆ Visit() [24/24]

void Aspose::Pdf::Annotations::AnnotationSelector::Visit ( System::SharedPtr< PDF3DAnnotation pdf3D)

Select PDF3D annotation if AnnotationSelector was initialized with PDF3DAnnotation object.

Parameters
pdf3DPDF3DAnnotation object for selecting.

Member Data Documentation

◆ annotation

System::SharedPtr<Annotation> Aspose::Pdf::Annotations::AnnotationSelector::annotation
protected

◆ selected

System::SharedPtr<System::Collections::Generic::List<System::SharedPtr<Annotation> > > Aspose::Pdf::Annotations::AnnotationSelector::selected
protected