KIM API V2
KIM_ModelCreate.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--2018, 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-v2.0.0-beta.0 package.
31 //
32 
33 
34 #ifndef KIM_MODEL_CREATE_HPP_
35 #define KIM_MODEL_CREATE_HPP_
36 
37 #include <string>
38 #include <sstream>
39 
40 #ifndef KIM_FUNC_HPP_
41 #include "KIM_func.hpp"
42 #endif
43 
44 
45 namespace KIM
46 {
47 // Forward declarations
48 class LogVerbosity;
49 class LanguageName;
50 class Numbering;
51 class SpeciesName;
52 class SupportStatus;
53 class LengthUnit;
54 class EnergyUnit;
55 class ChargeUnit;
56 class TemperatureUnit;
57 class TimeUnit;
58 class ModelCreateImplementation;
59 
60 
62 {
63  public:
64  int SetModelNumbering(Numbering const numbering);
65 
66  void SetInfluenceDistancePointer(double const * const influenceDistance);
67 
68  void SetNeighborListCutoffsPointer(int const numberOfCutoffs,
69  double const * const cutoffs);
70 
71  int SetRefreshPointer(LanguageName const languageName, func * const fptr);
72  int SetDestroyPointer(LanguageName const languageName, func * const fptr);
73  int SetComputeArgumentsCreatePointer(LanguageName const languageName,
74  func * const fptr);
75  int SetComputeArgumentsDestroyPointer(LanguageName const languageName,
76  func * const fptr);
77  int SetComputePointer(LanguageName const languageName, func * const fptr);
78 
79  int SetSpeciesCode(SpeciesName const speciesName, int const code);
80 
81  int SetParameterPointer(int const extent, int * const ptr,
82  std::string const & description);
83  int SetParameterPointer(int const extent, double * const ptr,
84  std::string const & description);
85 
86  void SetModelBufferPointer(void * const ptr);
87 
88  int SetUnits(LengthUnit const lengthUnit,
89  EnergyUnit const energyUnit,
90  ChargeUnit const chargeUnit,
91  TemperatureUnit const temperatureUnit,
92  TimeUnit const timeUnit);
93 
94  int ConvertUnit(
95  LengthUnit const fromLengthUnit,
96  EnergyUnit const fromEnergyUnit,
97  ChargeUnit const fromChargeUnit,
98  TemperatureUnit const fromTemperatureUnit,
99  TimeUnit const fromTimeUnit,
100  LengthUnit const toLengthUnit,
101  EnergyUnit const toEnergyUnit,
102  ChargeUnit const toChargeUnit,
103  TemperatureUnit const toTemperatureUnit,
104  TimeUnit const toTimeUnit,
105  double const lengthExponent,
106  double const energyExponent,
107  double const chargeExponent,
108  double const temperatureExponent,
109  double const timeExponent,
110  double * const conversionFactor) const;
111 
112  void LogEntry(LogVerbosity const logVerbosity, std::string const & message,
113  int const lineNumber, std::string const & fileName) const;
114  void LogEntry(LogVerbosity const logVerbosity,
115  std::stringstream const & message,
116  int const lineNumber, std::string const & fileName) const;
117 
118  std::string const & String() const;
119 
120  private:
121  // do not allow copy constructor or operator=
122  ModelCreate(ModelCreate const &);
123  void operator=(ModelCreate const &);
124 
125  ModelCreate();
126  ~ModelCreate();
127 
128  ModelCreateImplementation * pimpl;
129 }; // class ModelCreate
130 } // namespace KIM
131 #endif // KIM_MODEL_CREATE_HPP_
void LogEntry(LogVerbosity const logVerbosity, std::string const &message, int const lineNumber, std::string const &fileName) const
int SetSpeciesCode(SpeciesName const speciesName, int const code)
int SetModelNumbering(Numbering const numbering)
int SetComputePointer(LanguageName const languageName, func *const fptr)
int SetUnits(LengthUnit const lengthUnit, EnergyUnit const energyUnit, ChargeUnit const chargeUnit, TemperatureUnit const temperatureUnit, TimeUnit const timeUnit)
void SetInfluenceDistancePointer(double const *const influenceDistance)
void SetModelBufferPointer(void *const ptr)
int SetParameterPointer(int const extent, int *const ptr, std::string const &description)
int SetComputeArgumentsDestroyPointer(LanguageName const languageName, func *const fptr)
int SetComputeArgumentsCreatePointer(LanguageName const languageName, func *const fptr)
int SetRefreshPointer(LanguageName const languageName, func *const fptr)
std::string const & String() const
void SetNeighborListCutoffsPointer(int const numberOfCutoffs, double const *const cutoffs)
int ConvertUnit(LengthUnit const fromLengthUnit, EnergyUnit const fromEnergyUnit, ChargeUnit const fromChargeUnit, TemperatureUnit const fromTemperatureUnit, TimeUnit const fromTimeUnit, LengthUnit const toLengthUnit, EnergyUnit const toEnergyUnit, ChargeUnit const toChargeUnit, TemperatureUnit const toTemperatureUnit, TimeUnit const toTimeUnit, double const lengthExponent, double const energyExponent, double const chargeExponent, double const temperatureExponent, double const timeExponent, double *const conversionFactor) const
void() func()
Definition: KIM_func.hpp:40
int SetDestroyPointer(LanguageName const languageName, func *const fptr)