cfdm.DomainTopology.set_cell¶
-
DomainTopology.
set_cell
(cell)[source]¶ Set the cell type.
The cell type indicates the common spatial dimensionality of the cells, one of:
'point'
: A point is zero-dimensional and has no boundaryvertices.
'edge'
: An edge is one-dimensional and corresponds to aline connecting two boundary vertices.
'face'
: A face is two-dimensional and corresponds to asurface enclosed by a set of edges.
New in version (cfdm): 1.11.0.0
Examples
>>> d = cfdm.DomainTopology() >>> d.has_cell() False >>> d.set_cell('face') >>> d.has_cell() True >>> d.get_cell() 'face' >>> d.del_cell() 'face' >>> d.get_cell() Traceback (most recent call last): ... ValueError: DomainTopology has no 'cell' component >>> print(d.get_cell(None)) None