Object_Sync_Sf_Rest
Object_Sync_Sf_Rest class.
Table of Contents
- $file : string
- The main plugin file
- $mappings : object
- Object_Sync_Sf_Mapping class
- $option_prefix : string
- The plugin's prefix when saving options to the database
- $pull : object
- Object_Sync_Sf_Salesforce_Pull class
- $push : object
- Object_Sync_Sf_Salesforce_Push class
- $salesforce : array<string|int, mixed>
- Object_Sync_Sf_Salesforce class This contains Salesforce API methods
- $slug : string
- The plugin's slug so we can include it when necessary
- $version : string
- Current version of the plugin
- $wordpress : object
- Object_Sync_Sf_WordPress class
- $wpdb : object
- Global object of `$wpdb`, the WordPress database
- $namespace : string
- The namespace for the REST endpoints
- $sfwp_transients : object
- Object_Sync_Sf_WordPress_Transient class
- __construct() : mixed
- Constructor for rest class
- add_actions() : mixed
- Create the action hooks to create the reset methods
- can_process() : mixed
- Check to see if the user has permission to do this
- check_class() : bool
- Check for a valid class from the parameter
- check_id() : bool
- Check for a valid ID from the parameter. This one is not in use yet.
- process() : array<string|int, mixed>
- Process the REST API request
- register_routes() : mixed
- Register REST API routes
Properties
$file
The main plugin file
public
string
$file
$mappings
Object_Sync_Sf_Mapping class
public
object
$mappings
$option_prefix
The plugin's prefix when saving options to the database
public
string
$option_prefix
$pull
Object_Sync_Sf_Salesforce_Pull class
public
object
$pull
$push
Object_Sync_Sf_Salesforce_Push class
public
object
$push
$salesforce
Object_Sync_Sf_Salesforce class This contains Salesforce API methods
public
array<string|int, mixed>
$salesforce
$slug
The plugin's slug so we can include it when necessary
public
string
$slug
$version
Current version of the plugin
public
string
$version
$wordpress
Object_Sync_Sf_WordPress class
public
object
$wordpress
$wpdb
Global object of `$wpdb`, the WordPress database
public
object
$wpdb
$namespace
The namespace for the REST endpoints
private
string
$namespace
$sfwp_transients
Object_Sync_Sf_WordPress_Transient class
private
object
$sfwp_transients
Methods
__construct()
Constructor for rest class
public
__construct() : mixed
Return values
mixed —add_actions()
Create the action hooks to create the reset methods
public
add_actions() : mixed
Return values
mixed —can_process()
Check to see if the user has permission to do this
public
can_process(WP_REST_Request $request) : mixed
Parameters
- $request : WP_REST_Request
-
the request object sent to the API.
Return values
mixed —check_class()
Check for a valid class from the parameter
public
check_class(string $class) : bool
Parameters
- $class : string
-
check if the class is a real object.
Return values
bool —check_id()
Check for a valid ID from the parameter. This one is not in use yet.
public
check_id(string $id) : bool
Parameters
- $id : string
-
check if the ID from the parameter is a real object.
Return values
bool —process()
Process the REST API request
public
process(WP_REST_Request $request) : array<string|int, mixed>
Parameters
- $request : WP_REST_Request
-
the request that was made.
Return values
array<string|int, mixed> —$result
register_routes()
Register REST API routes
public
register_routes() : mixed