[SOLVED] Making this rule generic

Here’s the problem. Everyone treats them as out of scope for their docs. OH doesn’t document them because they are not implemented by openHAB. Xtend doesn’t document them because they are not implemented by Xtend/Xtext. They are actually implemented by the underlying Java Stream interface so you have to go to the JavaDocs to find the official docs.

That’s one reason why I wrote Design Pattern: Working with Groups in Rules which provides some documentation for the more common methods we would want to use in an OH context. The Xtend docs actually does refer to these methods, but only in their Movies example.

1 Like