Merge remote-tracking branch 'origin/4.5' into 4.5-master-2015-02-24-17-24-05
[civicrm-core.git] / api / v3 / ParticipantPayment.php
index 7d7729163e1fadca7d2892fa5f02885ee6ad7255..dcade2067a36cf41a534d8c184844fea46ca9e75 100644 (file)
@@ -1,5 +1,4 @@
 <?php
-
 /*
  +--------------------------------------------------------------------+
  | CiviCRM version 4.6                                                |
  */
 
 /**
- * File for the CiviCRM APIv3 participant functions
+ * This api exposes CiviCRM participant payments.
  *
  * @package CiviCRM_APIv3
- * @subpackage API_Participant
- *
- * @copyright CiviCRM LLC (c) 2004-2014
- * @version $Id: Participant.php 30486 2010-11-02 16:12:09Z shot $
- *
- */
-
-/**
- * Files required for this package
  */
 
 /**
- * Create a Event Participant Payment
+ * Create a Event Participant Payment.
  *
  * This API is used for creating a Participant Payment of Event.
- * Required parameters : participant_id, contribution_id.
+ * Required parameters: participant_id, contribution_id.
  *
- * @param   array  $params     an associative array of name/value property values of civicrm_participant_payment
- * @example ParticipantPaymentCreate.php
- * {@example ParticipantPaymentCreate.php 0}
+ * @param array $params
+ *   An associative array of name/value property values of civicrm_participant_payment.
  *
- * @return array of newly created payment property values.
- * {@getfields ParticipantPayment_create}
- * @access public
+ * @return array
  */
 function civicrm_api3_participant_payment_create($params) {
 
@@ -70,10 +57,12 @@ function civicrm_api3_participant_payment_create($params) {
 }
 
 /**
- * Adjust Metadata for Create action
+ * Adjust Metadata for Create action.
+ *
+ * The metadata is used for setting defaults, documentation & validation.
  *
- * The metadata is used for setting defaults, documentation & validation
- * @param array $params array or parameters determined by getfields
+ * @param array $params
+ *   Array of parameters determined by getfields.
  */
 function _civicrm_api3_participant_payment_create_spec(&$params) {
   $params['participant_id']['api.required'] = 1;
@@ -81,16 +70,12 @@ function _civicrm_api3_participant_payment_create_spec(&$params) {
 }
 
 /**
- * Deletes an existing Participant Payment
- *
- * This API is used for deleting a Participant Payment
+ * Deletes an existing Participant Payment.
  *
  * @param array $params
  *
- * @return array API result
- * @example ParticipantPaymentDelete.php
- * {@getfields ParticipantPayment_delete}
- * @access public
+ * @return array
+ *   API result
  */
 function civicrm_api3_participant_payment_delete($params) {
   $participant = new CRM_Event_BAO_ParticipantPayment();
@@ -98,17 +83,14 @@ function civicrm_api3_participant_payment_delete($params) {
 }
 
 /**
- * Retrieve one / all contribution(s) / participant(s) linked to a
- * contribution.
+ * Retrieve one or more participant payment records.
  *
- * @param  array   $params  input parameters
+ * @param array $params
+ *   Input parameters.
  *
- * @return array  array of properties, if error an array with an error id and error message
- *  @example ParticipantPaymentGet
- * {@getfields ParticipantPayment_get}
- * @access public
+ * @return array
+ *   array of properties, if error an array with an error id and error message
  */
 function civicrm_api3_participant_payment_get($params) {
   return _civicrm_api3_basic_get('CRM_Event_DAO_ParticipantPayment', $params);
 }
-