Architecture Arcade
Architecture Commune Arcade
Api.hpp
Go to the documentation of this file.
1 /*
2 ** EPITECH PROJECT, 2023
3 ** Archi Arcade Promo 2026 Toulouse
4 ** File description:
5 ** Api to access the lib in .so files
6 */
7 
8 #pragma once
9 
10 #include "IDisplayModule.hpp"
11 #include "IGameModule.hpp"
12 
13 #ifdef _WIN32
14  #define EXPORT __declspec(dllexport)
15 #else
16  #define EXPORT
17 #endif
18 
24 extern "C"
25 {
26  enum LibType { GRAPH, GAME };
27 
42 
57  Arcade::Graph::IDisplayModule *displayModule);
58 
66  EXPORT const char *getName();
67 
76 }
EXPORT void destroyGameModule(Arcade::Game::IGameModule *gameModule)
Destroy the GameModule created by getGameModule.
EXPORT const char * getName()
The Shared lib entry point to get lib name.
EXPORT void destroyDisplayModule(Arcade::Graph::IDisplayModule *displayModule)
Destroy the DisplayModule created by getDisplayModule.
#define EXPORT
Definition: Api.hpp:16
LibType
Definition: Api.hpp:26
@ GRAPH
Definition: Api.hpp:26
@ GAME
Definition: Api.hpp:26
EXPORT Arcade::Graph::IDisplayModule * getDisplayModule()
The Graphs shared lib main entry point to get DisplayModule.
EXPORT LibType getType()
The Shared lib entry point to get lib type.
EXPORT Arcade::Game::IGameModule * getGameModule()
The Games shared lib main entry point to get GameModule.
The IGameModule interface.
Definition: IGameModule.hpp:24
The IDisplayModule interface.
Definition: IDisplayModule.hpp:21