kim-api  2.1.2+v2.1.2.GNU
An Application Programming Interface (API) for the Knowledgebase of Interatomic Models (KIM).
KIM_FunctionTypes.hpp
Go to the documentation of this file.
1 //
2 // CDDL HEADER START
3 //
4 // The contents of this file are subject to the terms of the Common Development
5 // and Distribution License Version 1.0 (the "License").
6 //
7 // You can obtain a copy of the license at
8 // http://www.opensource.org/licenses/CDDL-1.0. See the License for the
9 // specific language governing permissions and limitations under the License.
10 //
11 // When distributing Covered Code, include this CDDL HEADER in each file and
12 // include the License file in a prominent location with the name LICENSE.CDDL.
13 // If applicable, add the following below this CDDL HEADER, with the fields
14 // enclosed by brackets "[]" replaced with your own identifying information:
15 //
16 // Portions Copyright (c) [yyyy] [name of copyright owner]. All rights reserved.
17 //
18 // CDDL HEADER END
19 //
20 
21 //
22 // Copyright (c) 2016--2019, Regents of the University of Minnesota.
23 // All rights reserved.
24 //
25 // Contributors:
26 // Ryan S. Elliott
27 //
28 
29 //
30 // Release: This file is part of the kim-api-2.1.2 package.
31 //
32 
33 
34 #ifndef KIM_FUNCTION_TYPES_HPP_
35 #define KIM_FUNCTION_TYPES_HPP_
36 
37 namespace KIM
38 {
39 // Forward declarations
40 class LengthUnit;
41 class EnergyUnit;
42 class ChargeUnit;
43 class TemperatureUnit;
44 class TimeUnit;
45 class ModelCreate;
46 class ModelDriverCreate;
47 class ModelCompute;
48 class ModelExtension;
49 class ModelComputeArgumentsCreate;
50 class ModelComputeArguments;
51 class ModelRefresh;
52 class ModelWriteParameterizedModel;
53 class ModelComputeArgumentsDestroy;
54 class ModelDestroy;
55 
61 typedef void(Function)(void); // Generic function pointer
62 
68 typedef int ModelCreateFunction(ModelCreate * const modelCreate,
69  LengthUnit const requestedLengthUnit,
70  EnergyUnit const requestedEnergyUnit,
71  ChargeUnit const requestedChargeUnit,
72  TemperatureUnit const requestedTemperatureUnit,
73  TimeUnit const requestedTimeUnit);
74 
80 typedef int
81 ModelDriverCreateFunction(ModelDriverCreate * const modelDriverCreate,
82  LengthUnit const requestedLengthUnit,
83  EnergyUnit const requestedEnergyUnit,
84  ChargeUnit const requestedChargeUnit,
85  TemperatureUnit const requestedTemperatureUnit,
86  TimeUnit const requestedTimeUnit);
87 
96  ModelCompute const * const modelCompute,
97  ModelComputeArgumentsCreate * const modelComputeArgumentsCreate);
98 
105  ModelCompute const * const modelCompute,
106  ModelComputeArguments const * const modelComputeArgumentsCreate);
107 
114 typedef int GetNeighborListFunction(void * const dataObject,
115  int const numberOfNeighborLists,
116  double const * const cutoffs,
117  int const neighborListIndex,
118  int const particleNumber,
119  int * const numberOfNeighbors,
120  int const ** const neighborsOfParticle);
121 
129 typedef int ProcessDEDrTermFunction(void * const dataObject,
130  double const de,
131  double const r,
132  double const * const dx,
133  int const i,
134  int const j);
135 
144 typedef int ProcessD2EDr2TermFunction(void * const dataObject,
145  double const de,
146  double const * const r,
147  double const * const dx,
148  int const * const i,
149  int const * const j);
150 
156 typedef int ModelExtensionFunction(ModelExtension * const modelExtension,
157  void * const extensionStructure);
158 
165 typedef int ModelRefreshFunction(ModelRefresh * const modelRefresh);
166 
174  ModelWriteParameterizedModel const * const modelWriteParameterizedModel);
175 
184  ModelCompute const * const modelCompute,
185  ModelComputeArgumentsDestroy * const modelComputeArgumentsDestroy);
186 
192 typedef int ModelDestroyFunction(ModelDestroy * const modelDestroy);
193 } // namespace KIM
194 
195 #endif // KIM_FUNCTION_TYPES_HPP_
int ModelComputeArgumentsDestroyFunction(ModelCompute const *const modelCompute, ModelComputeArgumentsDestroy *const modelComputeArgumentsDestroy)
Prototype for MODEL_ROUTINE_NAME::ComputeArgumentsDestroy routine.
Provides the interface to a KIM API Model object for use by models within their MODEL_ROUTINE_NAME::R...
An Extensible Enumeration for the TemperatureUnit's supported by the KIM API.
An Extensible Enumeration for the TimeUnit's supported by the KIM API.
int ModelDestroyFunction(ModelDestroy *const modelDestroy)
Prototype for MODEL_ROUTINE_NAME::Destroy routine.
Provides the interface to a KIM API Model object for use by models within their MODEL_ROUTINE_NAME::W...
int ModelComputeFunction(ModelCompute const *const modelCompute, ModelComputeArguments const *const modelComputeArgumentsCreate)
Prototype for MODEL_ROUTINE_NAME::Compute routine.
int ProcessDEDrTermFunction(void *const dataObject, double const de, double const r, double const *const dx, int const i, int const j)
Prototype for COMPUTE_CALLBACK_NAME::ProcessDEDrTerm routine.
An Extensible Enumeration for the LengthUnit's supported by the KIM API.
void() Function(void)
Generic function type.
Provides the interface to a KIM API Model object for use by models within their MODEL_ROUTINE_NAME::D...
int ModelComputeArgumentsCreateFunction(ModelCompute const *const modelCompute, ModelComputeArgumentsCreate *const modelComputeArgumentsCreate)
Prototype for MODEL_ROUTINE_NAME::ComputeArgumentsCreate routine.
Provides the interface to a KIM API Model object for use by models within their MODEL_ROUTINE_NAME::C...
Provides the interface to a KIM API Model object for use by models within their MODEL_ROUTINE_NAME::C...
Provides the interface to a KIM API ComputeArguments object for use by models within their MODEL_ROUT...
An Extensible Enumeration for the EnergyUnit's supported by the KIM API.
Provides the interface to a KIM API Model object for use by models within their MODEL_ROUTINE_NAME::E...
int ModelRefreshFunction(ModelRefresh *const modelRefresh)
Prototype for MODEL_ROUTINE_NAME::Refresh routine.
Provides the interface to a KIM API ComputeArguments object for use by models within their MODEL_ROUT...
int ProcessD2EDr2TermFunction(void *const dataObject, double const de, double const *const r, double const *const dx, int const *const i, int const *const j)
Prototype for COMPUTE_CALLBACK_NAME::ProcessD2EDr2Term routine.
Provides the interface to a KIM API ComputeArguments object for use by models within their MODEL_ROUT...
int GetNeighborListFunction(void *const dataObject, int const numberOfNeighborLists, double const *const cutoffs, int const neighborListIndex, int const particleNumber, int *const numberOfNeighbors, int const **const neighborsOfParticle)
Prototype for COMPUTE_CALLBACK_NAME::GetNeighborList routine.
int ModelCreateFunction(ModelCreate *const modelCreate, LengthUnit const requestedLengthUnit, EnergyUnit const requestedEnergyUnit, ChargeUnit const requestedChargeUnit, TemperatureUnit const requestedTemperatureUnit, TimeUnit const requestedTimeUnit)
Prototype for MODEL_ROUTINE_NAME::Create routine.
An Extensible Enumeration for the ChargeUnit's supported by the KIM API.
Provides the interface to a KIM API Model object for use by models within their MODEL_ROUTINE_NAME::C...
int ModelExtensionFunction(ModelExtension *const modelExtension, void *const extensionStructure)
Prototype for MODEL_ROUTINE_NAME::Extension routine.
int ModelWriteParameterizedModelFunction(ModelWriteParameterizedModel const *const modelWriteParameterizedModel)
Prototype for MODEL_ROUTINE_NAME::WriteParameterizedModel routine.
int ModelDriverCreateFunction(ModelDriverCreate *const modelDriverCreate, LengthUnit const requestedLengthUnit, EnergyUnit const requestedEnergyUnit, ChargeUnit const requestedChargeUnit, TemperatureUnit const requestedTemperatureUnit, TimeUnit const requestedTimeUnit)
Prototype for MODEL_ROUTINE_NAME::Create routine.