Arcane  v3.16.6.0
Documentation développeur
Chargement...
Recherche...
Aucune correspondance
IFactoryService.h
1// -*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-
2//-----------------------------------------------------------------------------
3// Copyright 2000-2025 CEA (www.cea.fr) IFPEN (www.ifpenergiesnouvelles.com)
4// See the top-level COPYRIGHT file for details.
5// SPDX-License-Identifier: Apache-2.0
6//-----------------------------------------------------------------------------
7/*---------------------------------------------------------------------------*/
8/* IFactoryService.h (C) 2000-2025 */
9/* */
10/* Interface d'un service de fabrique. */
11/*---------------------------------------------------------------------------*/
12#ifndef ARCANE_CORE_IFACTORYSERVICE_H
13#define ARCANE_CORE_IFACTORYSERVICE_H
14/*---------------------------------------------------------------------------*/
15/*---------------------------------------------------------------------------*/
16
17#include "arcane/core/IService.h"
18#include "arcane/core/ServiceBuildInfo.h"
19
20/*---------------------------------------------------------------------------*/
21/*---------------------------------------------------------------------------*/
22
23namespace Arcane
24{
25
26/*---------------------------------------------------------------------------*/
27/*---------------------------------------------------------------------------*/
32template <typename InterfaceType>
33class IFactoryServiceT
34: public IService
35{
36 protected:
37
38 IFactoryServiceT() = default;
39
40 public:
41
47 virtual InterfaceType* createInstance() = 0;
48
56 virtual InterfaceType* createInstance(IMesh* mesh) = 0;
57
63 virtual InterfaceType* singletonInstance() = 0;
64};
65
66/*---------------------------------------------------------------------------*/
67/*---------------------------------------------------------------------------*/
68
69} // namespace Arcane
70
71/*---------------------------------------------------------------------------*/
72/*---------------------------------------------------------------------------*/
73
74#endif
75
virtual InterfaceType * singletonInstance()=0
Créé une instance singleton.
virtual InterfaceType * createInstance()=0
Créé une instance.
virtual InterfaceType * createInstance(IMesh *mesh)=0
Créé une instance pour le maillage mesh.
IService()
Constructeur.
Definition IService.h:43
-*- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature -*-