changed_fields_basic_usage.observer.inc in Changed Fields API 7.2
Same filename and directory in other branches
Observer example.
File
examples/changed_fields_basic_usage/includes/changed_fields_basic_usage.observer.incView source
<?php
/**
* @file
* Observer example.
*/
/**
* Class BasicUsageObserver.
*/
class BasicUsageObserver extends CFObserver {
/**
* {@inheritdoc}
*/
public function update(CFSubjectInterface $nodeSubject) {
$node = $nodeSubject
->getNode();
$changedFields = $nodeSubject
->getChangedFields();
// Do something with $node depends on $changedFields.
}
}
Classes
Name | Description |
---|---|
BasicUsageObserver | Class BasicUsageObserver. |