CFx SDK Documentation 2024 SP0
Loading...
Searching...
No Matches
PdfImport.h
Go to the documentation of this file.
1
2// Copyright (C) 2002-2022, Open Design Alliance (the "Alliance").
3// All rights reserved.
4//
5// This software and its documentation and related materials are owned by
6// the Alliance. The software may only be incorporated into application
7// programs owned by members of the Alliance, subject to a signed
8// Membership Agreement and Supplemental Software License Agreement with the
9// Alliance. The structure and organization of this software are the valuable
10// trade secrets of the Alliance and its suppliers. The software is also
11// protected by copyright law and international treaty provisions. Application
12// programs incorporating this software must include the following statement
13// with their copyright notices:
14//
15// This application incorporates Open Design Alliance software pursuant to a license
16// agreement with Open Design Alliance.
17// Open Design Alliance Copyright (C) 2002-2022 by Open Design Alliance.
18// All rights reserved.
19//
20// By use of this software, its documentation or related materials, you
21// acknowledge and accept the above terms.
23
24#ifndef _PDFIMPORT_INCLUDED_
25#define _PDFIMPORT_INCLUDED_
26
27#include "RxModule.h"
28#include "RxDictionary.h"
29#include "DynamicLinker.h"
30
32
33#include "OdPlatformSettings.h"
34#include <functional>
35
36#ifdef PDFIMPORT_EXPORTS
37 #define PDFIMPORT_TOOLKIT OD_TOOLKIT_EXPORT
38 #define PDFIMPORT_TOOLKIT_STATIC OD_STATIC_EXPORT
39#else
40 #define PDFIMPORT_TOOLKIT OD_TOOLKIT_IMPORT
41 #define PDFIMPORT_TOOLKIT_STATIC OD_STATIC_IMPORT
42#endif
43
45
46class OdDbDatabase;
47
57using PreferableFontCallback = std::function<OdAnsiString(const char*, const char*, const bool)>;
58
59//DD:EXPORT_ON
60
65class OdPdfImport : public OdRxObject
66{
67public:
72 {
93 };
94
102 virtual ImportResult import() = 0;
103
260
268};
269
274
280{
281public:
282
287 virtual OdPdfImportPtr create () = 0;
288
289};
290
295
296
303{
305 if ( !pModule.isNull() ) return pModule->create ();
306 return (OdPdfImport*)0;
307}
308
309//DD:EXPORT_OFF
310
311#endif // _PDFIMPORT_INCLUDED_
FIRSTDLL_EXPORT OdRxDynamicLinker * odrxDynamicLinker()
#define OdPdfImportModuleName
OdPdfImportPtr createImporter()
Definition: PdfImport.h:302
std::function< OdAnsiString(const char *, const char *, const bool)> PreferableFontCallback
Definition: PdfImport.h:57
OdSmartPtr< OdPdfImport > OdPdfImportPtr
Definition: PdfImport.h:273
OdSmartPtr< OdPdfImportModule > OdPdfImportModulePtr
Definition: PdfImport.h:294
bool isNull() const
Definition: BaseObjectPtr.h:86
virtual OdRxDictionaryPtr properties()=0
virtual void setPreferableFontCallback(PreferableFontCallback callback)=0
@ encrypted_file
Definition: PdfImport.h:84
@ bad_database
Definition: PdfImport.h:82
@ image_file_error
Definition: PdfImport.h:88
@ bad_password
Definition: PdfImport.h:78
@ invalid_page_number
Definition: PdfImport.h:86
@ no_objects_imported
Definition: PdfImport.h:90
@ font_file_error
Definition: PdfImport.h:92
virtual OdPdfImportPtr create()=0
virtual OdRxModulePtr loadApp(const OdString &applicationName, bool silent=true)=0