diff --git a/FAQ.md b/FAQ.md new file mode 100644 index 0000000..74f8e9f --- /dev/null +++ b/FAQ.md @@ -0,0 +1,29 @@ +# FAQ + +## What happens if I store a null value? + +Null values are stored normally. Listeners will be notified if the null differs from the previous value. + +## Can a listener remove itself? + +Yes, a listener can call `Ctx.INSTANCE.removeListener(...)` on itself if needed. + +## What if a listener throws an exception? + +Exceptions thrown in one listener will not stop other listeners from being notified, but you should handle exceptions inside the listener code. + +## Can I use primitive types? + +Yes, via their boxed equivalents, e.g. `Integer`, `Double`, etc. + +## How about arrays? + +Yes, arrays are supported and compared using `Objects.deepEquals`. + +## How to test with mocks? + +Use a mock of the `Listener` interface. The key-based typing makes it easy to isolate in unit tests. + +--- + +[[Home]] | [[API Reference]] | [[Programming Guide]] \ No newline at end of file