use pyo3::prelude::*;
pub fn register_module(py: Python<'_>, parent_module: &PyModule) -> PyResult<()>
{
let swfjc = PyModule::new(py, "swfjc")?;
super::thermodynamics::py::register_module(py, swfjc)?;
parent_module.add_submodule(swfjc)?;
swfjc.add_class::<SWFJC>()?;
Ok(())
}
#[pyclass]
pub struct SWFJC
{
#[pyo3(get)]
pub hinge_mass: f64,
#[pyo3(get)]
pub link_length: f64,
#[pyo3(get)]
pub number_of_links: u8,
#[pyo3(get)]
pub well_width: f64,
#[pyo3(get)]
pub thermodynamics: super::thermodynamics::py::SWFJC
}
#[pymethods]
impl SWFJC
{
#[new]
pub fn init(number_of_links: u8, link_length: f64, hinge_mass: f64, well_width: f64) -> Self
{
SWFJC
{
hinge_mass,
link_length,
number_of_links,
well_width,
thermodynamics: super::thermodynamics::py::SWFJC::init(number_of_links, link_length, hinge_mass, well_width)
}
}
}