Skip to content

Implement __contains__ for timeseries.Bounds and timeseries.SystemBounds #950

@llucax

Description

@llucax

What's needed?

It would be nice to be able to write:

if value in bounds:
    do_something(value)
else:
    raise OutOfBounds(value)

Proposed solution

Implement __contains__() for both classes.

Metadata

Metadata

Assignees

No one assigned

    Labels

    part:microgridAffects the interactions with the microgridtype:enhancementNew feature or enhancement visitble to users

    Type

    No type

    Projects

    Status

    Done

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions