russcip 0.1.8

Rust interface for SCIP.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
use crate::ffi;


pub struct Constraint{
    pub(crate) raw: *mut ffi::SCIP_CONS,
}

impl Constraint {
    pub fn get_name(&self) -> String {
        unsafe {
            let name = ffi::SCIPconsGetName(self.raw);
            String::from(std::ffi::CStr::from_ptr(name).to_str().unwrap())
        }
    }
}