class BasicUsageObserver in Changed Fields API 7.2
Same name and namespace in other branches
Class BasicUsageObserver.
Hierarchy
- class \CFObserver implements CFObserverInterface
- class \BasicUsageObserver
Expanded class hierarchy of BasicUsageObserver
File
- examples/
changed_fields_basic_usage/ includes/ changed_fields_basic_usage.observer.inc, line 11 - Observer example.
View source
class BasicUsageObserver extends CFObserver {
/**
* {@inheritdoc}
*/
public function update(CFSubjectInterface $nodeSubject) {
$node = $nodeSubject
->getNode();
$changedFields = $nodeSubject
->getChangedFields();
// Do something with $node depends on $changedFields.
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
BasicUsageObserver:: |
public | function |
Update method with info about event. Overrides CFObserver:: |
|
CFObserver:: |
private | property | Observer unique identifier. | |
CFObserver:: |
public | function |
Method to get observer id. Overrides CFObserverInterface:: |
|
CFObserver:: |
public | function | Observer constructor. |