HtmlDiffOutputGenerator.h
1 #pragma once
2 // Copyright (c) 2001-2024 Aspose Pty Ltd. All Rights Reserved.
3 
4 #include <system/string.h>
5 
6 #include "Aspose.PDF.Cpp/Comparison/OutputGenerator/IStringOutputGenerator.h"
7 #include "Aspose.PDF.Cpp/Comparison/OutputGenerator/IFileOutputGenerator.h"
8 #include "Aspose.PDF.Cpp/aspose_pdf_api_defs.h"
9 
10 namespace Aspose
11 {
12 namespace Pdf
13 {
14 namespace Comparison
15 {
16 namespace Diff
17 {
18 class DiffOperation;
19 } // namespace Diff
20 namespace OutputGenerator
21 {
22 class OutputTextStyle;
23 } // namespace OutputGenerator
24 } // namespace Comparison
25 } // namespace Pdf
26 } // namespace Aspose
27 namespace System
28 {
29 namespace Collections
30 {
31 namespace Generic
32 {
33 template <typename> class List;
34 } // namespace Generic
35 } // namespace Collections
36 namespace Text
37 {
38 namespace RegularExpressions
39 {
40 class Match;
41 class Regex;
42 } // namespace RegularExpressions
43 class StringBuilder;
44 } // namespace Text
45 } // namespace System
46 
47 namespace Aspose {
48 
49 namespace Pdf {
50 
51 namespace Comparison {
52 
53 namespace OutputGenerator {
54 
60 {
64 
65  typedef ::System::BaseTypesInfo<BaseType, BaseType1> ThisTypeBaseTypesInfo;
66  ASPOSE_PDF_SHARED_RTTI_INFO_DECL();
67 
68 public:
69 
74  ASPOSE_PDF_SHARED_API System::String get_EqualStyle() const;
79  ASPOSE_PDF_SHARED_API void set_EqualStyle(System::String value);
84  ASPOSE_PDF_SHARED_API System::String get_InsertStyle() const;
89  ASPOSE_PDF_SHARED_API void set_InsertStyle(System::String value);
94  ASPOSE_PDF_SHARED_API System::String get_DeleteStyle() const;
99  ASPOSE_PDF_SHARED_API void set_DeleteStyle(System::String value);
104  ASPOSE_PDF_SHARED_API bool get_StrikethroughDeleted() const;
109  ASPOSE_PDF_SHARED_API void set_StrikethroughDeleted(bool value);
110 
114  ASPOSE_PDF_SHARED_API HtmlDiffOutputGenerator();
119  ASPOSE_PDF_SHARED_API HtmlDiffOutputGenerator(System::SharedPtr<OutputTextStyle> textStyle);
120 
131  ASPOSE_PDF_SHARED_API void GenerateOutput(System::SharedPtr<System::Collections::Generic::List<System::SharedPtr<Aspose::Pdf::Comparison::Diff::DiffOperation>>> diffrences, System::String targetFilePath) override;
143 
144 private:
145 
146  System::String pr_EqualStyle;
147  System::String pr_InsertStyle;
148  System::String pr_DeleteStyle;
149  bool pr_StrikethroughDeleted;
150  System::String _newLineBr;
153  static const System::String DeleteClassName;
154  static const System::String InsertClassName;
155  static const System::String EqualClassName;
156  static const System::String StrikethroughClassName;
157  static const System::String StrikethroughStyle;
158 
159  void InitDefaultStyles();
163  System::String GetHtmlHead();
164  System::String GetHtmlClosingEnd();
165  System::String PrepareStyles();
166  void AddStyle(System::SharedPtr<System::Text::StringBuilder> strb, System::String styleName, System::String styleText);
167 
168 };
169 
170 } // namespace OutputGenerator
171 } // namespace Comparison
172 } // namespace Pdf
173 } // namespace Aspose
174 
175 
Represents a pointer to the method that compares two objects of the same type. This type should be al...
Definition: comparison.h:92
String class used across the library. Is a substitute for C# System.String when translating code...
Definition: string.h:121
class ASPOSECPP_SHARED_CLASS List
Definition: ienumerable.h:17
Definition: Artifact.h:71
Represents an interface for generating output to a file of differences between texts.
Definition: IFileOutputGenerator.h:44
Pointer class to wrap types being allocated on heap. Use it to manage memory for classes inheriting O...
Definition: SideBySidePdfComparer.h:24
Definition: AFRelationship.h:4
Buffer to accumulate string part by part. This type can be allocated either in stack as value type or...
Definition: string_builder.h:16
Single match of regexp over string. Objects of this class should only be allocated using System::Make...
Definition: match.h:55
Represents an interface for generating output to a string of differences between texts.
Definition: IStringOutputGenerator.h:44
List forward declaration.
Definition: Artifact.h:78
Regular expression that follows C#-like syntax. Objects of this class should only be allocated using ...
Definition: regex.h:29
Represents a class for generating html representation of texts differences. Deleted line breaks are i...
Definition: HtmlDiffOutputGenerator.h:59
Whole PDF file will be submitted.