2.1.43. czekitout.check.if_single_dim_slice_like
- if_single_dim_slice_like(obj, obj_name)[source]
Check whether input object is a one-dimensional slice-like object.
We define a one-dimensional slice-like object as any object that is an integer, a sequence of integers, or a slice object.
If the input object is not one-dimensional slice-like, then a TypeError exception is raised with the message:
The object ``<obj_name>`` must be an integer, a sequence of integers, or a `slice` object.
where <obj_name> is replaced by the contents of the string
obj_name
.- Parameters:
- objany type
Input object.
- obj_namestr
Name of the input object.