1af0996ceSBarry Smith #include <petsc/private/pcimpl.h> /*I "petscpc.h" I*/ 2245f004bSJed Brown 3245f004bSJed Brown /*@C 4a5b23f4aSJose E. Roman PCPythonSetType - Initialize a PC object implemented in Python. 5245f004bSJed Brown 6245f004bSJed Brown Collective on PC 7245f004bSJed Brown 8d8d19677SJose E. Roman Input Parameters: 9245f004bSJed Brown + pc - the preconditioner (PC) context. 10245f004bSJed Brown - pyname - full dotted Python name [package].module[.{class|function}] 11245f004bSJed Brown 12245f004bSJed Brown Options Database Key: 1367b8a455SSatish Balay . -pc_python_type <pyname> - python class 14245f004bSJed Brown 15245f004bSJed Brown Level: intermediate 16245f004bSJed Brown 17245f004bSJed Brown .seealso: PCCreate(), PCSetType(), PCPYTHON, PetscPythonInitialize() 18245f004bSJed Brown @*/ 19245f004bSJed Brown PetscErrorCode PCPythonSetType(PC pc,const char pyname[]) 20245f004bSJed Brown { 21245f004bSJed Brown PetscFunctionBegin; 22245f004bSJed Brown PetscValidHeaderSpecific(pc,PC_CLASSID,1); 23245f004bSJed Brown PetscValidCharPointer(pyname,2); 24*cac4c232SBarry Smith PetscTryMethod(pc,"PCPythonSetType_C",(PC, const char[]),(pc,pyname)); 25245f004bSJed Brown PetscFunctionReturn(0); 26245f004bSJed Brown } 27