interface SalesforceMappingInterface in Salesforce Suite 5.0.x
Same name and namespace in other branches
- 8.4 modules/salesforce_mapping/src/Entity/SalesforceMappingInterface.php \Drupal\salesforce_mapping\Entity\SalesforceMappingInterface
- 8.3 modules/salesforce_mapping/src/Entity/SalesforceMappingInterface.php \Drupal\salesforce_mapping\Entity\SalesforceMappingInterface
Mapping between Drupal and Salesforce records.
Hierarchy
- interface \Drupal\Core\Config\Entity\ConfigEntityInterface; interface \Drupal\Core\Entity\EntityWithPluginCollectionInterface
- interface \Drupal\salesforce_mapping\Entity\SalesforceMappingInterface
Expanded class hierarchy of SalesforceMappingInterface
All classes that implement SalesforceMappingInterface
32 files declare their use of SalesforceMappingInterface
- Broken.php in modules/
salesforce_mapping/ src/ Plugin/ SalesforceMappingField/ Broken.php - Constant.php in modules/
salesforce_mapping/ src/ Plugin/ SalesforceMappingField/ Constant.php - DeleteHandlerTest.php in modules/
salesforce_pull/ tests/ src/ Unit/ DeleteHandlerTest.php - DrupalConstant.php in modules/
salesforce_mapping/ src/ Plugin/ SalesforceMappingField/ DrupalConstant.php - Hardcoded.php in modules/
salesforce_example/ src/ Plugin/ SalesforceMappingField/ Hardcoded.php
File
- modules/
salesforce_mapping/ src/ Entity/ SalesforceMappingInterface.php, line 12
Namespace
Drupal\salesforce_mapping\EntityView source
interface SalesforceMappingInterface extends ConfigEntityInterface, EntityWithPluginCollectionInterface {
/**
* Magic getter method for mapping properties.
*
* @param string $key
* The property to get.
*
* @return mixed
* The value.
*/
public function __get($key);
/**
* Get all the mapped field plugins for this mapping.
*
* @return \Drupal\salesforce_mapping\SalesforceMappingFieldPluginInterface[]
* The fields.
*/
public function getFieldMappings();
/**
* Given a field config, create an instance of a field mapping.
*
* @param array $field
* Field plugin definition. Keys are "drupal_field_type" and "config".
*
* @return \Drupal\salesforce_mapping\SalesforceMappingFieldPluginInterface
* The field.
*/
public function getFieldMapping(array $field);
/**
* Get the Salesforce Object type name for this mapping, e.g. "Contact".
*
* @return string
* The object name.
*/
public function getSalesforceObjectType();
/**
* Get the Drupal entity type name for this mapping, e.g. "node".
*
* @return string
* The entity type id.
*/
public function getDrupalEntityType();
/**
* Get the Drupal bundle name for this mapping, e.g. "article".
*
* @return string
* The bundle.
*/
public function getDrupalBundle();
/**
* Get all the field plugins which are configured to pull from Salesforce.
*
* @return \Drupal\salesforce_mapping\SalesforceMappingFieldPluginInterface[]
* Array of objects.
*/
public function getPullFields();
/**
* Get a flat array of the field plugins which are configured to pull.
*
* @return array
* Keys and values are Salesforce field names.
*/
public function getPullFieldsArray();
/**
* The Salesforce date field which determines whether to pull.
*
* @return string
* SF field name.
*/
public function getPullTriggerDate();
/**
* Getter for push_standalone property.
*
* @return bool
* TRUE if this mapping is set to process push queue via a standalone
* endpoint instead of during cron.
*/
public function doesPushStandalone();
/**
* Getter for push_standalone property.
*
* @return bool
* TRUE if this mapping is set to process push queue via a standalone
* endpoint instead of during cron.
*/
public function doesPullStandalone();
/**
* Checks mappings for any push operation.
*
* @return bool
* TRUE if this mapping is configured to push.
*/
public function doesPush();
/**
* Checks mappings for any pull operation.
*
* @return bool
* TRUE if this mapping is configured to pull.
*/
public function doesPull();
/**
* Checks if mapping has any of the given triggers.
*
* @param array $triggers
* Collection of SALESFORCE_MAPPING_SYNC_* constants from MappingConstants.
*
* @see \Drupal\salesforce_mapping\MappingConstants
*
* @return bool
* TRUE if any of the given $triggers are enabled for this mapping.
*/
public function checkTriggers(array $triggers);
/**
* Return TRUE if an upsert key is set for this mapping.
*
* @return bool
* Return TRUE if an upsert key is set for this mapping.
*/
public function hasKey();
/**
* Return name of the Salesforce field which is the upsert key.
*
* @return string
* The upsert key Salesforce field name.
*/
public function getKeyField();
/**
* Given a Drupal entity, get the value to be upserted.
*
* @return mixed
* The upsert field value.
*/
public function getKeyValue(EntityInterface $entity);
/**
* Return the timestamp for the date of most recent delete processing.
*
* @return int|null
* Integer timestamp of last delete, or NULL if delete has not been run.
*/
public function getLastDeleteTime();
/**
* Set this mapping as having been last processed for deletes at $time.
*
* @param int $time
* The delete time to set.
*
* @return $this
*/
public function setLastDeleteTime($time);
/**
* Return the timestamp for the date of most recent pull processing.
*
* @return mixed
* Integer timestamp of last pull, or NULL if pull has not been run.
*/
public function getLastPullTime();
/**
* Set this mapping as having been last pulled at $time.
*
* @param int $time
* The pull time to set.
*
* @return $this
*/
public function setLastPullTime($time);
/**
* Get the timestamp when the next pull should be processed for this mapping.
*
* @return int
* The next pull time.
*/
public function getNextPullTime();
/**
* Generate a select query to pull records from Salesforce for this mapping.
*
* @param array $mapped_fields
* Fetch only these fields, if given, otherwise fetch all mapped fields.
* @param int $start
* Timestamp of starting window from which to pull records. If omitted, use
* ::getLastPullTime()
* @param int $stop
* Timestamp of ending window from which to pull records. If omitted, use
* "now".
*
* @return \Drupal\salesforce\SelectQuery
* The pull query.
*/
public function getPullQuery(array $mapped_fields = [], $start = 0, $stop = 0);
/**
* Returns a timstamp when the push queue was last processed for this mapping.
*
* @return int|null
* The last push time, or NULL.
*/
public function getLastPushTime();
/**
* Set the timestamp when the push queue was last process for this mapping.
*
* @param string $time
* The push time to set.
*
* @return $this
*/
public function setLastPushTime($time);
/**
* Get the timestamp when the next push should be processed for this mapping.
*
* @return int
* The next push time.
*/
public function getNextPushTime();
/**
* Return TRUE if this mapping should always use upsert over create or update.
*
* @return bool
* Whether to upsert, ignoring any local Salesforce ID.
*/
public function alwaysUpsert();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
AccessibleInterface:: |
public | function | Checks data value access. | 9 |
CacheableDependencyInterface:: |
public | function | The cache contexts associated with this object. | 34 |
CacheableDependencyInterface:: |
public | function | The maximum age for which this object may be cached. | 34 |
CacheableDependencyInterface:: |
public | function | The cache tags associated with this object. | 27 |
ConfigEntityInterface:: |
public | function | Calculates dependencies and stores them in the dependency property. | 2 |
ConfigEntityInterface:: |
public | function | Disables the configuration entity. | 2 |
ConfigEntityInterface:: |
public | function | Enables the configuration entity. | 2 |
ConfigEntityInterface:: |
public | function | Returns the value of a property. | 2 |
ConfigEntityInterface:: |
public | function | Gets the configuration dependencies. | 2 |
ConfigEntityInterface:: |
public | function | Gets whether on not the data is trusted. | 2 |
ConfigEntityInterface:: |
public | function | Checks whether this entity is installable. | 2 |
ConfigEntityInterface:: |
public | function | Returns whether this entity is being changed during the uninstall process. | 2 |
ConfigEntityInterface:: |
public | function | Informs the entity that entities it depends on will be deleted. | 2 |
ConfigEntityInterface:: |
public | function | Sets the value of a property. | 2 |
ConfigEntityInterface:: |
public | function | Sets the status of the configuration entity. | 2 |
ConfigEntityInterface:: |
public | function | Returns whether the configuration entity is enabled. | 2 |
ConfigEntityInterface:: |
public | function | Sets that the data should be trusted. | 2 |
EntityInterface:: |
public | function | Gets the bundle of the entity. | 2 |
EntityInterface:: |
public static | function | Constructs a new entity object, without permanently saving it. | 2 |
EntityInterface:: |
public | function | Creates a duplicate of the entity. | 2 |
EntityInterface:: |
public | function | Deletes an entity permanently. | 2 |
EntityInterface:: |
public | function | Enforces an entity to be new. | 2 |
EntityInterface:: |
public | function | Returns the cache tags that should be used to invalidate caches. | 2 |
EntityInterface:: |
public | function | Gets the key that is used to store configuration dependencies. | 2 |
EntityInterface:: |
public | function | Gets the configuration dependency name. | 2 |
EntityInterface:: |
public | function | Gets the configuration target identifier for the entity. | 2 |
EntityInterface:: |
public | function | Gets the entity type definition. | 2 |
EntityInterface:: |
public | function | Gets the ID of the type of the entity. | 2 |
EntityInterface:: |
public | function | Gets the original ID. | 2 |
EntityInterface:: |
public | function | Gets a typed data object for this entity object. | 2 |
EntityInterface:: |
public | function | Indicates if a link template exists for a given key. | 2 |
EntityInterface:: |
public | function | Gets the identifier. | 2 |
EntityInterface:: |
public | function | Determines whether the entity is new. | 2 |
EntityInterface:: |
public | function | Gets the label of the entity. | 2 |
EntityInterface:: |
public | function | Gets the language of the entity. | 2 |
EntityInterface:: |
public static | function | Loads an entity. | 2 |
EntityInterface:: |
public static | function | Loads one or more entities. | 2 |
EntityInterface:: |
public | function | Acts on a created entity before hooks are invoked. | 2 |
EntityInterface:: |
public static | function | Acts on deleted entities before the delete hook is invoked. | 2 |
EntityInterface:: |
public static | function | Acts on loaded entities. | 3 |
EntityInterface:: |
public | function | Acts on a saved entity before the insert or update hook is invoked. | 2 |
EntityInterface:: |
public static | function | Changes the values of an entity before it is created. | 2 |
EntityInterface:: |
public static | function | Acts on entities before they are deleted and before hooks are invoked. | 2 |
EntityInterface:: |
public | function | Acts on an entity before the presave hook is invoked. | 2 |
EntityInterface:: |
public | function | Gets a list of entities referenced by this entity. | 2 |
EntityInterface:: |
public | function | Saves an entity permanently. | 2 |
EntityInterface:: |
public | function | Sets the original ID. | 2 |
EntityInterface:: |
public | function | Gets an array of all property values. | 3 |
EntityInterface:: |
public | function | Generates the HTML for a link to this entity. | 2 |
EntityInterface:: |
public | function | Gets the URL object for the entity. | 2 |
EntityInterface:: |
public | function | Gets a list of URI relationships supported by this entity. | 2 |
EntityInterface:: |
public | function | Gets the entity UUID (Universally Unique Identifier). | 2 |
ObjectWithPluginCollectionInterface:: |
public | function | Gets the plugin collections used by this object. | 11 |
RefinableCacheableDependencyInterface:: |
public | function | Adds a dependency on an object: merges its cacheability metadata. | 1 |
RefinableCacheableDependencyInterface:: |
public | function | Adds cache contexts. | 1 |
RefinableCacheableDependencyInterface:: |
public | function | Adds cache tags. | 1 |
RefinableCacheableDependencyInterface:: |
public | function | Merges the maximum age (in seconds) with the existing maximum age. | 1 |
SalesforceMappingInterface:: |
public | function | Return TRUE if this mapping should always use upsert over create or update. | 1 |
SalesforceMappingInterface:: |
public | function | Checks if mapping has any of the given triggers. | 1 |
SalesforceMappingInterface:: |
public | function | Checks mappings for any pull operation. | 1 |
SalesforceMappingInterface:: |
public | function | Getter for push_standalone property. | 1 |
SalesforceMappingInterface:: |
public | function | Checks mappings for any push operation. | 1 |
SalesforceMappingInterface:: |
public | function | Getter for push_standalone property. | 1 |
SalesforceMappingInterface:: |
public | function | Get the Drupal bundle name for this mapping, e.g. "article". | 1 |
SalesforceMappingInterface:: |
public | function | Get the Drupal entity type name for this mapping, e.g. "node". | 1 |
SalesforceMappingInterface:: |
public | function | Given a field config, create an instance of a field mapping. | 1 |
SalesforceMappingInterface:: |
public | function | Get all the mapped field plugins for this mapping. | 1 |
SalesforceMappingInterface:: |
public | function | Return name of the Salesforce field which is the upsert key. | 1 |
SalesforceMappingInterface:: |
public | function | Given a Drupal entity, get the value to be upserted. | 1 |
SalesforceMappingInterface:: |
public | function | Return the timestamp for the date of most recent delete processing. | 1 |
SalesforceMappingInterface:: |
public | function | Return the timestamp for the date of most recent pull processing. | 1 |
SalesforceMappingInterface:: |
public | function | Returns a timstamp when the push queue was last processed for this mapping. | 1 |
SalesforceMappingInterface:: |
public | function | Get the timestamp when the next pull should be processed for this mapping. | 1 |
SalesforceMappingInterface:: |
public | function | Get the timestamp when the next push should be processed for this mapping. | 1 |
SalesforceMappingInterface:: |
public | function | Get all the field plugins which are configured to pull from Salesforce. | 1 |
SalesforceMappingInterface:: |
public | function | Get a flat array of the field plugins which are configured to pull. | 1 |
SalesforceMappingInterface:: |
public | function | Generate a select query to pull records from Salesforce for this mapping. | 1 |
SalesforceMappingInterface:: |
public | function | The Salesforce date field which determines whether to pull. | 1 |
SalesforceMappingInterface:: |
public | function | Get the Salesforce Object type name for this mapping, e.g. "Contact". | 1 |
SalesforceMappingInterface:: |
public | function | Return TRUE if an upsert key is set for this mapping. | 1 |
SalesforceMappingInterface:: |
public | function | Set this mapping as having been last processed for deletes at $time. | 1 |
SalesforceMappingInterface:: |
public | function | Set this mapping as having been last pulled at $time. | 1 |
SalesforceMappingInterface:: |
public | function | Set the timestamp when the push queue was last process for this mapping. | 1 |
SalesforceMappingInterface:: |
public | function | Magic getter method for mapping properties. | 1 |
SynchronizableInterface:: |
public | function | Returns whether this entity is being changed as part of a synchronization. | 1 |
SynchronizableInterface:: |
public | function | Sets the status of the synchronization flag. | 1 |
ThirdPartySettingsInterface:: |
public | function | Gets the list of third parties that store information. | 5 |
ThirdPartySettingsInterface:: |
public | function | Gets the value of a third-party setting. | 5 |
ThirdPartySettingsInterface:: |
public | function | Gets all third-party settings of a given module. | 5 |
ThirdPartySettingsInterface:: |
public | function | Sets the value of a third-party setting. | 5 |
ThirdPartySettingsInterface:: |
public | function | Unsets a third-party setting. | 5 |