HAL  v4.5.0-83-g30c8f0afc
The Hardware Analyzer - a comprehensive reverse engineering and manipulation framework for gate-level netlists.
plugin_gexf_writer.cpp
Go to the documentation of this file.
2 
5 
6 namespace hal
7 {
8  extern std::unique_ptr<BasePluginInterface> create_plugin_instance()
9  {
10  return std::make_unique<GexfWriterPlugin>();
11  }
12 
14  : FacExtensionInterface(FacExtensionInterface::FacNetlistWriter)
15  {
16  m_description = "Default GEXF Writer";
17  m_supported_file_extensions.push_back(".gexf");
19  fac->m_factory = []() { return std::make_unique<GexfWriter>(); };
20  factory_provider = fac;
21  }
22 
24  : m_extension(nullptr)
25  {;}
26 
27  std::string GexfWriterPlugin::get_name() const
28  {
29  return std::string("gexf_writer");
30  }
31 
32  std::string GexfWriterPlugin::get_version() const
33  {
34  return std::string("0.1");
35  }
36 
38  {
39  m_extension = new GexfWriterExtension;
40  m_extensions.push_back(m_extension);
41  }
42 
44  {
45  delete_extension(m_extension);
46  }
47 } // namespace hal
void delete_extension(AbstractExtensionInterface *aeif)
std::vector< AbstractExtensionInterface * > m_extensions
std::vector< std::string > m_supported_file_extensions
AbstractFactoryProvider * factory_provider
std::function< std::unique_ptr< T >)> m_factory
std::string get_version() const override
std::string get_name() const override
Definition: defines.h:45
std::unique_ptr< BasePluginInterface > create_plugin_instance()