CharInfoCollection.h
1 #pragma once
2 // Copyright (c) 2001-2024 Aspose Pty Ltd. All Rights Reserved.
3 
4 #include <system/collections/ienumerator.h>
5 #include <system/collections/icollection.h>
6 #include <system/array.h>
7 #include <cstdint>
8 
9 #include "Aspose.PDF.Cpp/aspose_pdf_api_defs.h"
10 
11 namespace Aspose
12 {
13 namespace Pdf
14 {
15 namespace Collections
16 {
17 template <typename, typename> class AsposeHashDictionary;
18 } // namespace Collections
19 namespace Text
20 {
21 class CharInfo;
22 class TextSegment;
23 } // namespace Text
24 } // namespace Pdf
25 } // namespace Aspose
26 
27 namespace Aspose {
28 
29 namespace Pdf {
30 
31 namespace Text {
32 
41 class ASPOSE_PDF_SHARED_CLASS CharInfoCollection final : public System::Collections::Generic::ICollection<System::SharedPtr<Aspose::Pdf::Text::CharInfo>>
42 {
45 
46  typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
47  ASPOSE_PDF_SHARED_RTTI_INFO_DECL();
48 
50 
51 private:
52 
53  class CharInfoEnumerator : public System::Collections::Generic::IEnumerator<System::SharedPtr<Aspose::Pdf::Text::CharInfo>>
54  {
55  typedef CharInfoEnumerator ThisType;
57 
58  typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
59  RTTI_INFO_DECL();
60  CODEPORTING_ENUMERATOR_ITERATOR_METHODS_DECLARATION(CODEPORTING_ARGS(System::SharedPtr<CharInfo>), CODEPORTING_NO_API_KEYWORD);
61 
62  public:
63 
64  const System::SharedPtr<CharInfo>& get_Current() const override;
65 
66  CharInfoEnumerator(System::SharedPtr<CharInfoCollection> charInfoCollection);
67 
68  bool MoveNext() override;
69  void Reset() override;
70  void Dispose() override;
71 
72  private:
73 
74  int32_t current;
75  System::SharedPtr<CharInfoCollection> charInfoCollection;
76 
77  bool MoveNextImplementation();
78  System::SharedPtr<CharInfo>* GetCurrentElementPointer();
79 
80  };
81 
82 
83 public:
84 
88  ASPOSE_PDF_SHARED_API int32_t get_Count() const override;
92  ASPOSE_PDF_SHARED_API System::SharedPtr<System::Object> get_SyncRoot() const;
96  ASPOSE_PDF_SHARED_API bool get_IsSynchronized();
100  ASPOSE_PDF_SHARED_API bool get_IsReadOnly() const override;
101 
112  //[Obfuscation(Feature = "virtualization", Exclude = false)]
113  ASPOSE_PDF_SHARED_API void CopyTo(System::ArrayPtr<System::SharedPtr<CharInfo>> array, int32_t index) override;
118  ASPOSE_PDF_SHARED_API void Add(const System::SharedPtr<CharInfo>& item) override;
122  ASPOSE_PDF_SHARED_API void Clear() override;
128  ASPOSE_PDF_SHARED_API bool Contains(const System::SharedPtr<CharInfo>& item) const override;
134  ASPOSE_PDF_SHARED_API bool Remove(const System::SharedPtr<CharInfo>& item) override;
135 
141  //[Obfuscation(Feature = "virtualization", Exclude = false)]
142  ASPOSE_PDF_SHARED_API System::SharedPtr<CharInfo> idx_get(int32_t index);
143 
144 protected:
145 
150 
151  MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION(CharInfoCollection, CODEPORTING_ARGS(System::SharedPtr<TextSegment> textSegment));
152 
153  virtual ASPOSE_PDF_SHARED_API ~CharInfoCollection();
154 
155 private:
156 
159  System::WeakPtr<TextSegment> textSegment;
160 
161 };
162 
163 } // namespace Text
164 } // namespace Pdf
165 } // namespace Aspose
166 
167 
Represents segment of Pdf text.
Definition: TextSegment.h:137
Represents CharInfo objects collection.
Definition: CharInfoCollection.h:41
Pointer class to wrap types being allocated on heap. Use it to manage memory for classes inheriting O...
Definition: fwd.h:22
Represents a text type.
Interface of enumerator which can be used to iterate through some elements. Objects of this class sho...
Definition: BaseOperatorCollection.h:47
Definition: AFRelationship.h:4
Subclass of System::SmartPtr which sets itself to weak mode at construction. Please note that this cl...
Definition: TextFragmentState.h:69
Interface of collection of elements. Objects of this class should only be allocated using System::Mak...
Definition: Collection.h:41
Whole PDF file will be submitted.