safeAdd method
Adds an event to this controller if it is not closed.
Returns true if the event was added successfully, or false if
the controller was already closed.
Implementation
bool safeAdd(T event) {
if (isClosed) return false;
try {
add(event);
return true;
} catch (e) {
// Optionally log or handle internal add failures.
return false;
}
}