xref: /petsc/src/mat/tests/ex140.py (revision 3b9d9b6507112a6fc8ea0705b2a0df60b27b6bb4)
1from petsc4py import PETSc
2
3class Matrix(object):
4
5    def __init__(self):
6        pass
7
8    def create(self, mat):
9        pass
10
11    def destroy(self, mat):
12        pass
13
14    def setFromOptions(self, mat):
15        m = PETSc.Options().getString('enable',None)
16        if m is not None:
17          setattr(self,m,1)
18