mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2026-07-06 11:17:21 +02:00
fixed in developer via other PR
This commit is contained in:
@@ -30,17 +30,7 @@ def extract_enums(lines):
|
||||
|
||||
line_iter = iter(lines)
|
||||
enums = {}
|
||||
inside_defs = False
|
||||
|
||||
for line in line_iter:
|
||||
|
||||
# only pick up what is inside slsDetectorDefs
|
||||
if "class slsDetectorDefs" in line:
|
||||
inside_defs = True
|
||||
|
||||
if not inside_defs:
|
||||
continue
|
||||
|
||||
#Hack away class enum defs
|
||||
if "class" in line:
|
||||
line = line.replace("class", "")
|
||||
|
||||
@@ -30,6 +30,11 @@ void init_enums(py::module &m) {
|
||||
.value("MATTERHORN", slsDetectorDefs::detectorType::MATTERHORN)
|
||||
.export_values();
|
||||
|
||||
py::enum_<slsDetectorDefs::ReturnCode>(Defs, "ReturnCode")
|
||||
.value("OK", slsDetectorDefs::ReturnCode::OK)
|
||||
.value("FAIL", slsDetectorDefs::ReturnCode::FAIL)
|
||||
.export_values();
|
||||
|
||||
py::enum_<slsDetectorDefs::boolFormat>(Defs, "boolFormat")
|
||||
.value("TrueFalse", slsDetectorDefs::boolFormat::TrueFalse)
|
||||
.value("OnOff", slsDetectorDefs::boolFormat::OnOff)
|
||||
|
||||
Reference in New Issue
Block a user