cf.DomainAncillary.has_bounds

DomainAncillary.has_bounds()[source]

Whether or not there are bounds.

New in version (cfdm): 1.7.0

Returns
bool

True if there are bounds, otherwise False.

Examples

>>> c = cf.DomainAncillary()
>>> b = cf.Bounds(data=cf.Data(numpy.arange(10).reshape(5, 2)))
>>> c.set_bounds(b)
>>> c.has_bounds()
True
>>> c.get_bounds()
<CF Bounds: (5, 2) >
>>> b = c.del_bounds()
>>> b
<CF Bounds: (5, 2) >
>>> c.has_bounds()
False
>>> print(c.get_bounds(None))
None
>>> print(c.del_bounds(None))
None