PLaSK library
Loading...
Searching...
No Matches
your_solver.cpp
Go to the documentation of this file.
1
/*
2
* This file is part of PLaSK (https://plask.app) by Photonics Group at TUL
3
* Copyright (c) 2022 Lodz University of Technology
4
*
5
* This program is free software: you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License as published by
7
* the Free Software Foundation, version 3.
8
*
9
* This program is distributed in the hope that it will be useful,
10
* but WITHOUT ANY WARRANTY; without even the implied warranty of
11
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12
* GNU General Public License for more details.
13
*/
17
#include <cmath>
18
#include <plask/python.hpp>
19
using namespace
plask
;
20
using namespace
plask::python
;
21
22
#include "../your_solver_class_header.hpp"
23
using namespace
plask::category::your_solver
;
24
31
BOOST_PYTHON_MODULE
(solver_name)
32
{
33
{
CLASS
(
Class_Name
,
"YourSolver"
,
"Short solver description."
)
34
METHOD
(
python_method_name
,
method_name
,
"Short documentation"
,
"name_or_argument_1"
, arg(
"name_of_argument_2"
)=
default_value_of_arg_2
, ...);
35
RO_FIELD
(
field_name
,
"Short documentation"
);
// read-only field
36
RW_FIELD
(
field_name
,
"Short documentation"
);
// read-write field
37
RO_PROPERTY
(
python_property_name
,
get_method_name
,
"Short documentation"
);
// read-only property
38
RW_PROPERTY
(
python_property_name
,
get_method_name
,
set_method_name
,
"Short documentation"
);
// read-write property
39
RECEIVER
(
inReceiver
,
""
);
// receiver in the solver (string is an optional additional documentation)
40
PROVIDER
(
outProvider
,
""
);
// provider in the solver (string is an optional additional documentation)
41
BOUNDARY_CONDITIONS
(
boundary_conditions_name
,
"Short documentation"
);
// boundary conditions
42
}
43
44
}
45
solvers
skel
python
your_solver.cpp
Generated by
1.9.8