17 Commits

Author SHA1 Message Date
Michael Zanetti
92197cb97c Refactor NymeaCore class
This moves all the things and rules logic away from NymeaCore
into their respective modules where it belongs.

One major change is the removal of the removePolicy functionality.
This was somewhat broken as it was only working for rules but not
for all the other modules like scripts, experiences etc. After
an attempt to create something that works with all modules it
really seemed that this does not make a lot of sence after all,
given that updating rules would in most cases leave something
very broken behind and removing them was the only sane thing to do.

On the other hand, experience plugins may not work well with such
a policy eithre as they may require to do their own special thing.

So in the end the removePolicy was dropped altogether. Apps should
instead figure out themselves what removal of a thing may imply and
inform the user about that beforehand.
2023-01-24 17:56:04 +01:00
Simon Stürz
a3b3eecde8 Update debug prints and improve information given by warnings 2022-10-13 12:07:20 +02:00
Michael Zanetti
327fba5797 Fix creating rules without giving action params that have a default value 2022-09-07 20:25:33 +02:00
Jenkins nymea
3c8dd98400 Merge PR #500: Add debug prints to rule engine 2022-03-27 19:49:37 +02:00
Michael Zanetti
1f743b6671 Add debug prints to rule engine 2022-02-21 13:22:53 +01:00
Michael Zanetti
2a91dad1f0 Don't generate events for state changes any more
Up until now, nymea would generate EventTypes for every StateType
as well as emit an Event (along with a StateChanged notification) for
every change. This results in a lot of duplicated network traffic
which is of not much use. The StateChanged notification contains
all the information in the Event too and nymea:app actually never
really used Events for state changes.

This commit removes the events from the ThingClass, making it a lot
smaller and stops emitting Events for state changes.

As this is breaking the behavior, the JSONRPC API major version
is bumped.
2022-02-08 10:38:41 +01:00
Michael Zanetti
4290e01b1f Fix time based rules not being initialized directly after creation 2021-05-29 00:26:57 +02:00
Michael Zanetti
b9be92df2e Add state based value comparison in rules 2020-12-04 16:16:55 +01:00
Michael Zanetti
9f856f3ce9 Add support for generic IO connections 2020-05-01 14:43:23 +02:00
Michael Zanetti
8208473302 bump api 2020-03-05 16:16:57 +01:00
Michael Zanetti
3e425fc55b Rename devices to integrations/things 2020-03-02 13:40:26 +01:00
Michael Zanetti
8f5536ba1a Update copyright 2020-01-23 20:07:26 +01:00
Michael Zanetti
baaa719b6a Restructuring json done 2019-11-01 20:55:45 +01:00
Michael Zanetti
da0b7a04f8 Verify events coming from plugins 2019-08-23 12:10:07 +02:00
Michael Zanetti
1608e07d99 BrowserItems in rules working 2019-07-25 15:56:18 +02:00
Michael Zanetti
0fb42681af A little more work on browser item support for rules 2019-07-25 15:56:18 +02:00
Michael Zanetti
d24abfe3d0 Move devicemanager's implementation out of libnymea into libnymea-core 2019-07-15 22:52:52 +02:00