KIM API V2
KIM_ModelComputeArguments.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_COMPUTE_ARGUMENTS_HPP_
35 #define KIM_MODEL_COMPUTE_ARGUMENTS_HPP_
36 
37 #include <string>
38 #include <sstream>
39 
40 namespace KIM
41 {
42 // Forward declarations
43 class LogVerbosity;
44 class ComputeArgumentName;
45 class ComputeCallbackName;
46 class ModelComputeArgumentsImplementation;
47 
48 
50  public:
51  int GetNeighborList(int const neighborListIndex, int const particleNumber,
52  int * const numberOfNeighbors,
53  int const ** const neighborsOfParticle) const;
54 
55  int ProcessDEDrTerm(double const de, double const r, double const * const dx,
56  int const i, int const j) const;
57 
58  int ProcessD2EDr2Term(double const de, double const * const r,
59  double const * const dx, int const * const i,
60  int const * const j) const;
61 
62  int GetArgumentPointer(ComputeArgumentName const computeArgumentName,
63  int const ** const ptr) const;
64  int GetArgumentPointer(ComputeArgumentName const computeArgumentName,
65  int ** const ptr) const;
66  int GetArgumentPointer(ComputeArgumentName const computeArgumentName,
67  double const ** const ptr) const;
68  int GetArgumentPointer(ComputeArgumentName const computeArgumentName,
69  double ** const ptr) const;
70 
71  int IsCallbackPresent(ComputeCallbackName const computeCallbackName,
72  int * const present) const;
73 
74  void SetModelBufferPointer(void * const ptr);
75  void GetModelBufferPointer(void ** const ptr) const;
76 
77  void LogEntry(LogVerbosity const logVerbosity, std::string const & message,
78  int const lineNumber, std::string const & fileName) const;
79  void LogEntry(LogVerbosity const logVerbosity,
80  std::stringstream const & message,
81  int const lineNumber, std::string const & fileName) const;
82 
83  std::string const & String() const;
84 
85  private:
86  // do not allow copy constructor or operator=
88  void operator=(ModelComputeArguments const &);
89 
92 
93  ModelComputeArgumentsImplementation * pimpl;
94 }; // class ModelCompute
95 } // namespace KIM
96 #endif // KIM_MODEL_COMPUTE_HPP_
std::string const & String() const
int ProcessDEDrTerm(double const de, double const r, double const *const dx, int const i, int const j) const
int ProcessD2EDr2Term(double const de, double const *const r, double const *const dx, int const *const i, int const *const j) const
int GetArgumentPointer(ComputeArgumentName const computeArgumentName, int const **const ptr) const
void SetModelBufferPointer(void *const ptr)
void LogEntry(LogVerbosity const logVerbosity, std::string const &message, int const lineNumber, std::string const &fileName) const
int GetNeighborList(int const neighborListIndex, int const particleNumber, int *const numberOfNeighbors, int const **const neighborsOfParticle) const
void GetModelBufferPointer(void **const ptr) const
int IsCallbackPresent(ComputeCallbackName const computeCallbackName, int *const present) const