You are here

public function FeedsCommentProcessor::getMappingTargets in Feeds Comment Processor 6

Same name and namespace in other branches
  1. 7 FeedsCommentProcessor.inc \FeedsCommentProcessor::getMappingTargets()

Return available mapping targets.

Overrides FeedsProcessor::getMappingTargets

1 call to FeedsCommentProcessor::getMappingTargets()
FeedsCommentProcessor::setTargetElement in ./FeedsCommentProcessor.inc
Override setTargetElement to operate on a target item that is a comment.

File

./FeedsCommentProcessor.inc, line 246
Class definition of FeedsCommentProcessor.

Class

FeedsCommentProcessor
Creates comments from feed items.

Code

public function getMappingTargets() {
  $targets = array(
    'pid' => array(
      'name' => t('Parent ID'),
      'description' => t('The cid to which this comment is a reply.'),
    ),
    'nid' => array(
      'name' => t('Node ID'),
      'description' => t('The nid to which this comment is a reply.'),
    ),
    'uid' => array(
      'name' => t('User ID'),
      'description' => t('The Drupal user ID of the comment author.'),
    ),
    'subject' => array(
      'name' => t('Title'),
      'description' => t('The title of the comment.'),
    ),
    'comment' => array(
      'name' => t('Comment'),
      'description' => t('The comment body.'),
    ),
    'hostname' => array(
      'name' => t('Hostname'),
      'description' => t('The author\'s host name.'),
    ),
    'timestamp' => array(
      'name' => t('Published date'),
      'description' => t('The UNIX time when a comment has been saved.'),
    ),
    'status' => array(
      'name' => t('Published status'),
      'description' => t('The published status of a comment. (0 = Not Published, 1 = Published)'),
    ),
    'name' => array(
      'name' => t('Name'),
      'description' => t('The comment author\'s name.'),
    ),
    'mail' => array(
      'name' => t('Email'),
      'description' => t('The comment author\'s e-mail address.'),
    ),
    'homepage' => array(
      'name' => t('Homepage'),
      'description' => t('The comment author\'s home page address'),
    ),
    'guid' => array(
      'name' => t('GUID'),
      'description' => t('The external GUID of the comment. E. g. the feed item GUID in the case of a syndication feed. May be unique.'),
      'optional_unique' => TRUE,
    ),
  );

  // Let other modules expose mapping targets.
  self::loadMappers();
  drupal_alter('feeds_comment_processor_targets', $targets);
  return $targets;
}