Top "Observer-pattern" questions

A design pattern in which an object, called the subject, maintains a list of its dependents, called observers and notifies them automatically of any state changes, usually by calling one of their methods.

How to create a full Audit log in Rails for every table?

We recently began a compliance push at our company and are required to keep a full history of changes to …

ruby-on-rails ruby activerecord observer-pattern
Observers vs. Callbacks

i thought about using observers or callbacks. What and when you should use an observer? F.e. you could do …

ruby-on-rails callback observer-pattern
How to do Events in Ruby?

I come from a C# background, and have just started programming in Ruby. The thing is, that I need to …

ruby design-patterns events observer-pattern
Alternative to Java's Observable class?

I'm coming to Java from the C# world where the Observer pattern is implemented as a first-class language construct with …

java events observer-pattern observable
Publisher-subscriber vs Observer

I am trying to make sense of Observer design pattern as the main event dispatching design pattern. The Observer pattern …

design-patterns observer-pattern publish-subscribe event-dispatching
What is difference between observer pattern and reactive programming?

Recently I heard the term reactive programming a lot, but when I searched for it, what I discovered was only …

observer-pattern reactive-programming
A generic observer pattern in Java

The java.util.Observer and java.util.Observable are ugly. They require the sorts of casts that make type-safety fans …

java generics observer-pattern
magento $order->getAllItems() return twice the same item

I'm writing an observer that check every item in a order, at some point I get the items foreach($order-&…

php magento observer-pattern
Simple way of turning off observers during rake task?

I'm using restful_authentication in my app. I'm creating a set of default users using a rake task, but every …

ruby-on-rails ruby observer-pattern restful-authentication
Observable in Java

I'm trying to understand the Observer and the Observable. Here's an example that I'm trying to figure out: public class …

java oop design-patterns observer-pattern