Class RowRange (2.23.1)

RowRange(
    start_key: typing.Optional[typing.Union[str, bytes]] = None,
    end_key: typing.Optional[typing.Union[str, bytes]] = None,
    start_is_inclusive: typing.Optional[bool] = None,
    end_is_inclusive: typing.Optional[bool] = None,
)

Represents a range of keys in a ReadRowsQuery

Properties

end_is_inclusive

Returns whether the range is inclusive of the end key. Returns True if the range is unbounded on the right.

end_key

Returns the end key of the range. If None, the range is unbounded on the right.

start_is_inclusive

Returns whether the range is inclusive of the start key. Returns True if the range is unbounded on the left.

start_key

Returns the start key of the range. If None, the range is unbounded on the left.

Methods

RowRange

RowRange(
    start_key: typing.Optional[typing.Union[str, bytes]] = None,
    end_key: typing.Optional[typing.Union[str, bytes]] = None,
    start_is_inclusive: typing.Optional[bool] = None,
    end_is_inclusive: typing.Optional[bool] = None,
)
Exceptions
TypeDescription
ValueError: if start_key is greater than end_key, or start_is_inclusive, or end_is_inclusive is set when the corresponding key is None, or start_key or end_key is not a string or bytes.

__bool__

__bool__() -> bool

Empty RowRanges (representing a full table scan) are falsy, because they can be substituted with None. Non-empty RowRanges are truthy.

__str__

__str__() -> str

Represent range as a string, e.g. "[b'a', b'z)" Unbounded start or end keys are represented as "-inf" or "+inf"