Class: ModraUp::DefinitionObserver
- Inherits:
-
Object
- Object
- ModraUp::DefinitionObserver
Overview
Observer for a single component definition. Registered with ModraUp::ComponentDefinition#add_observer.
Instance Method Summary # collapse
-
#onComponentInstanceAdded(definition, instance) ⇒ nil
Called when an instance is added to this definition.
-
#onComponentInstanceRemoved(definition, instance) ⇒ nil
Called when an instance is removed from the definition. Triggers after operations like ModraUp::Group#explode / ModraUp::ComponentInstance#explode, and ModraUp::Group#union / ModraUp::Group#subtract / ModraUp::Group#trim consume their operands.
Instance Method Details
observer.onComponentInstanceAdded(definition, instance) ⇒ nil
Called when an instance is added to this definition.
observer.onComponentInstanceRemoved(definition, instance) ⇒ nil
Called when an instance is removed from the definition. Triggers after operations like ModraUp::Group#explode / ModraUp::ComponentInstance#explode, and ModraUp::Group#union / ModraUp::Group#subtract / ModraUp::Group#trim consume their operands.