ArcGIS Procedural Runtime  3.2.10650
ExtensionFactory.h
1 /*
2  COPYRIGHT (c) 2012-2024 Esri R&D Center Zurich
3  TRADE SECRETS: ESRI PROPRIETARY AND CONFIDENTIAL
4  Unpublished material - all rights reserved under the
5  Copyright Laws of the United States and applicable international
6  laws, treaties, and conventions.
7 
8  For additional information, contact:
9  Environmental Systems Research Institute, Inc.
10  Attn: Contracts and Legal Services Department
11  380 New York Street
12  Redlands, California, 92373
13  USA
14 
15  email: contracts@esri.com
16 */
17 
18 #ifndef PRTX_EXTENSIONFACTORY_H_
19 #define PRTX_EXTENSIONFACTORY_H_
20 
21 #include "prtx/prtx.h"
22 #include "prtx/URI.h"
23 #include "prtx/Extension.h"
24 
25 #ifdef _MSC_VER
26 # pragma warning(push)
27 # pragma warning(disable : 4275)
28 #endif
29 
30 
31 namespace prtx {
32 
33 
48 class PRTX_EXPORTS_API ExtensionFactory {
49 protected:
50  ExtensionFactory() = default;
51 
52 public:
53  ExtensionFactory(const ExtensionFactory&) = delete;
54  ExtensionFactory& operator=(const ExtensionFactory&) = delete;
55  virtual ~ExtensionFactory() = default;
56 
60  virtual Extension* create() const = 0;
61 
65  virtual const std::wstring& getID() const = 0;
66 
70  virtual const std::wstring& getName() const = 0;
71 
75  virtual const std::wstring& getDescription() const = 0;
76 
80  virtual prt::ContentType getContentType() const = 0;
81 
85  virtual prtx::Extension::ExtensionType getExtensionType() const = 0;
86 
92  virtual float getMerit() const { return getDefaultMerit(); }
93 
97  static float getDefaultMerit();
98 
103  virtual bool canHandleURI(prtx::URIPtr uri) const = 0;
104 };
105 
106 
107 } /* namespace prtx */
108 
109 
110 #ifdef _MSC_VER
111 # pragma warning(pop)
112 #endif
113 
114 
115 #endif /* PRTX_EXTENSIONFACTORY_H_ */
ExtensionType
Definition: Extension.h:46
Definition: ExtensionFactory.h:48
Definition: Extension.h:41
The Procedural Runtime eXtension namespace. The prtx namespace contains the tools to extend the Proce...
Definition: AnnotationBuilder.h:35
std::shared_ptr< URI > URIPtr
shared pointer implementation of prtx::URI
Definition: URI.h:37
ContentType
Definition: ContentType.h:28
virtual float getMerit() const
Definition: ExtensionFactory.h:92