Cantera  3.2.0a5
Loading...
Searching...
No Matches
ctrxn.h
Go to the documentation of this file.
1/**
2 * CTRXN - Generated CLib %Cantera interface library.
3 *
4 * @file ctrxn.h
5 *
6 * Generated CLib API for %Cantera's Reaction class.
7 *
8 * This library of functions is designed to encapsulate %Cantera functionality
9 * and make it available for use in languages and applications other than C++.
10 * A set of library functions is provided that are declared "extern C". All
11 * %Cantera objects are stored and referenced by integers - no pointers are
12 * passed to or from the calling application.
13 *
14 * This file was generated by sourcegen. It will be re-generated by the
15 * %Cantera build process. Do not manually edit.
16 *
17 * @warning This library is an experimental part of the %Cantera API and
18 * may be changed without notice.
19 */
20
21// This file is part of Cantera. See License.txt in the top-level directory or
22// at https://cantera.org/license.txt for license and copyright information.
23
24#ifndef CTRXN_H
25#define CTRXN_H
26
27#include <stdint.h> // for 32-bit int32_t / 64-bit int64_t
28
29#ifdef __cplusplus
30extern "C" {
31#endif
32
33 /**
34 * @defgroup CAPIctrxn ctrxn Library
35 * Generated CLib API for %Cantera's Reaction class.
36 *
37 * @warning This library is an experimental part of the %Cantera API and
38 * may be changed or removed without notice.
39 *
40 * @ingroup CAPIindex
41 */
42
43 /**
44 * @addtogroup CAPIctrxn
45 * @{
46 */
47
48 /**
49 * Instantiate Reaction object using default constructor.
50 *
51 * Wraps C++ constructor: `undefined`
52 *
53 * @returns Object handle if successful and -1 for exception handling.
54 */
55 int32_t rxn_new();
56
57 /**
58 * The chemical equation for this reaction.
59 *
60 * Wraps C++ getter: `string Reaction::equation()`
61 *
62 * @param handle Handle to queried Reaction object.
63 * @param[in] bufLen Length of reserved array.
64 * @param[out] buf Returned string value.
65 * @returns Actual length of string including string-terminating null byte, \0, or -1 for exception handling.
66 */
67 int32_t rxn_equation(int32_t handle, int32_t bufLen, char* buf);
68
69 /**
70 * The type of reaction, including reaction rate information.
71 *
72 * Wraps C++ getter: `string Reaction::type()`
73 *
74 * @param handle Handle to queried Reaction object.
75 * @param[in] bufLen Length of reserved array.
76 * @param[out] buf Returned string value.
77 * @returns Actual length of string including string-terminating null byte, \0, or -1 for exception handling.
78 */
79 int32_t rxn_type(int32_t handle, int32_t bufLen, char* buf);
80
81 /**
82 * Check whether reaction involves third body collider.
83 *
84 * Wraps C++ getter: `bool Reaction::usesThirdBody()`
85 *
86 * @param handle Handle to queried Reaction object.
87 */
88 int32_t rxn_usesThirdBody(int32_t handle);
89
90 /**
91 * Get validity flag of reaction.
92 *
93 * Wraps C++ getter: `bool Reaction::valid()`
94 *
95 * @param handle Handle to queried Reaction object.
96 */
97 int32_t rxn_valid(int32_t handle);
98
99 /**
100 * An identification string for the reaction, used in some filtering operations.
101 *
102 * Wraps C++ variable-getter: `string Reaction::id`
103 *
104 * @param handle Handle to queried Reaction object.
105 * @param[in] bufLen Length of reserved array.
106 * @param[out] buf Returned string value.
107 * @returns Actual length of string including string-terminating null byte, \0, or -1 for exception handling.
108 */
109 int32_t rxn_id(int32_t handle, int32_t bufLen, char* buf);
110
111 /**
112 * An identification string for the reaction, used in some filtering operations.
113 *
114 * Wraps C++ variable-setter: `string Reaction::id`
115 *
116 * @param handle Handle to queried Reaction object.
117 * @param[in] id An identification string for the reaction, used in some filtering operations.
118 */
119 int32_t rxn_setId(int32_t handle, const char* id);
120
121 /**
122 * True if reaction orders can be specified for non-reactant species.
123 *
124 * Wraps C++ variable-getter: `bool Reaction::allow_nonreactant_orders`
125 *
126 * @param handle Handle to queried Reaction object.
127 */
128 int32_t rxn_allowNonreactantOrders(int32_t handle);
129
130 /**
131 * True if reaction orders can be specified for non-reactant species.
132 *
133 * Wraps C++ variable-setter: `bool Reaction::allow_nonreactant_orders`
134 *
135 * @param handle Handle to queried Reaction object.
136 * @param[in] allow_nonreactant_orders True if reaction orders can be specified for non-reactant species.
137 */
138 int32_t rxn_setAllowNonreactantOrders(int32_t handle, int32_t allow_nonreactant_orders);
139
140 /**
141 * Delete Reaction object.
142 *
143 * Wraps C++ destructor: `undefined`
144 *
145 * @param handle Handle to Reaction object.
146 * @returns Zero for success and -1 for exception handling.
147 */
148 int32_t rxn_del(int32_t handle);
149
150 /**
151 * Return size of Reaction storage.
152 *
153 * Wraps C++ reserved CLib function: `custom code`
154 *
155 * @returns Size or -1 for exception handling.
156 */
157 int32_t rxn_cabinetSize();
158
159 /**
160 * @}
161 */
162
163#ifdef __cplusplus
164}
165#endif
166
167#endif // CTRXN_H
int32_t rxn_allowNonreactantOrders(int32_t handle)
True if reaction orders can be specified for non-reactant species.
Definition ctrxn.cpp:116
int32_t rxn_del(int32_t handle)
Delete Reaction object.
Definition ctrxn.cpp:139
int32_t rxn_new()
Instantiate Reaction object using default constructor.
Definition ctrxn.cpp:37
int32_t rxn_id(int32_t handle, int32_t bufLen, char *buf)
An identification string for the reaction, used in some filtering operations.
Definition ctrxn.cpp:93
int32_t rxn_setId(int32_t handle, const char *id)
An identification string for the reaction, used in some filtering operations.
Definition ctrxn.cpp:105
int32_t rxn_valid(int32_t handle)
Get validity flag of reaction.
Definition ctrxn.cpp:82
int32_t rxn_cabinetSize()
Return size of Reaction storage.
Definition ctrxn.cpp:150
int32_t rxn_type(int32_t handle, int32_t bufLen, char *buf)
The type of reaction, including reaction rate information.
Definition ctrxn.cpp:59
int32_t rxn_equation(int32_t handle, int32_t bufLen, char *buf)
The chemical equation for this reaction.
Definition ctrxn.cpp:47
int32_t rxn_usesThirdBody(int32_t handle)
Check whether reaction involves third body collider.
Definition ctrxn.cpp:71
int32_t rxn_setAllowNonreactantOrders(int32_t handle, int32_t allow_nonreactant_orders)
True if reaction orders can be specified for non-reactant species.
Definition ctrxn.cpp:127