Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[blockly] Persistence: Enhance existing blocks & add blocks to cover …
…all available actions (#2596) Closes #2595. This PR further extends the Blockly capabilities to include more of the persistence extensions. Specifically enhanced the `oh_get_persistvalue` block: - Add all `Between` methods of already existing methods - Add `countSince`, `countUntil` and `countBetween` - Add `countStateChangesSince`, `countStateChangesUntil` and `countStateChangesBetween` - Add `getAllStatesSince`, `getAllStatesUntil`, `getAllStatesBetween` returning an Array of timestamp and state pairs - Add a parameter for return type if relevant (`String`, `Number`, `Quantity`, `Timestamp`). Added methods to the `oh_get_persistence_lastupdate` block: - `lastChange`, `nextChange` Created a new block `oh_delete_persistedvalues` to delete persisted values: - `deleteAllStatesSince`, `deleteAllStatesUntil`, `deleteAllStatesBetween` Created a new block `oh_persist` to persist values: - `currentState`: persists a state at the current time - `stateAt`: persists a state to a given time - `stateList`: persists a TimeSeries --------- Signed-off-by: Mark Herwege <mark.herwege@telenet.be>
- Loading branch information