GF_Feed_Processor
GF_Feed_Processor Class.
Since: 2.2
Source: includes/addon/class-gf-feed-processor.php:18
Details
- Kind:
class - Namespace:
(global) - Extends:
GF_Background_Process
Properties
| Property | Type | Description |
|---|---|---|
$action | string | The action name. |
$supports_attempts | bool | Indicates if the task uses an array that supports the attempts key. |
$add_on | null | GFFeedAddOn | Null or the add-on instance. |
Methods
| Method | Description |
|---|---|
__construct() | Instantiates the class. |
get_instance() | Get instance of this class. |
push_to_queue() | Push to queue |
can_process_feed() | Determines if the feed can be processed based on the contents of the processed feeds entry meta. |
log_debug() | Writes a message to the add-on or core log. |
log_error() | Writes an error message to the add-on or core log. |
Method Reference
__construct()
public function __construct( $allowed_batch_data_classes=true, $add_on=null )
Instantiates the class.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$allowed_batch_data_classes | bool | array | true | Optional. Array of class names that can be unserialized. Default true (any class). |
$add_on | null | GFFeedAddOn | null | Optional. The add-on instance. |
Since: 2.9.25
Source: includes/addon/class-gf-feed-processor.php:65
get_instance()
public static function get_instance( $add_on=null )
Get instance of this class.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$add_on | null | GFFeedAddOn | null | Optional. The add-on instance. |
Returns
Since:
2.22.9.25(Added the $add_on param.)
Source: includes/addon/class-gf-feed-processor.php:83
push_to_queue()
public function push_to_queue( $data )
Push to queue
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$data | mixed | Data. |
Returns
$this
Since: 2.9.25
Source: includes/addon/class-gf-feed-processor.php:103
can_process_feed()
public function can_process_feed( $feed, $entry, $form, $addon )
Determines if the feed can be processed based on the contents of the processed feeds entry meta.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$feed | array | The feed queued for processing. | |
$entry | array | The entry being processed. | |
$form | array | The form the entry belongs to. | |
$addon | GFFeedAddOn | The current instance of the add-on the feed belongs to. |
Returns
bool
Since: 2.9.2
Source: includes/addon/class-gf-feed-processor.php:290
log_debug()
public function log_debug( $message )
Writes a message to the add-on or core log.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$message | string | The message to be logged. |
Returns
void
Since: 2.9.25
Source: includes/addon/class-gf-feed-processor.php:379
log_error()
public function log_error( $message )
Writes an error message to the add-on or core log.
Parameters
| Name | Type | Default | Description |
|---|---|---|---|
$message | string | The message to be logged. |
Returns
void
Since: 2.9.25
Source: includes/addon/class-gf-feed-processor.php:396