MCPcopy Create free account
hub / github.com/FreeCAD/FreeCAD / touch

Method touch

src/App/DocumentObjectPyImp.cpp:183–204  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

181}
182
183PyObject* DocumentObjectPy::touch(PyObject* args)
184{
185 char* propName = nullptr;
186 if (!PyArg_ParseTuple(args, "|s", &propName)) {
187 return nullptr;
188 }
189 if (propName) {
190 if (!propName[0]) {
191 getDocumentObjectPtr()->touch(true);
192 Py_Return;
193 }
194 auto prop = getDocumentObjectPtr()->getPropertyByName(propName);
195 if (!prop) {
196 throw Py::RuntimeError("Property not found");
197 }
198 prop->touch();
199 Py_Return;
200 }
201
202 getDocumentObjectPtr()->touch();
203 Py_Return;
204}
205
206PyObject* DocumentObjectPy::purgeTouched(PyObject* args)
207{

Callers

nothing calls this directly

Calls 1

getPropertyByNameMethod · 0.45

Tested by

no test coverage detected