Style - Remove @access
[civicrm-core.git] / CRM / Core / BAO / Job.php
index 0053f5a54845cd5ccd21c4c0a2f958b7a8ebe44a..016139474612fe740be6bb4ecf9c7497657c2691 100644 (file)
@@ -1,7 +1,7 @@
 <?php
 /*
  +--------------------------------------------------------------------+
- | CiviCRM version 4.5                                                |
+ | CiviCRM version 4.6                                                |
  +--------------------------------------------------------------------+
  | Copyright CiviCRM LLC (c) 2004-2014                                |
  +--------------------------------------------------------------------+
 class CRM_Core_BAO_Job extends CRM_Core_DAO_Job {
 
   /**
-   * class constructor
+   * Class constructor
    */
-  function __construct() {
+  public function __construct() {
     parent::__construct();
   }
 
   /**
-   * Function to add the payment-processor type in the db
+   * Add the payment-processor type in the db
    *
-   * @param array $params (reference ) an assoc array of name/value pairs
+   * @param array $params an assoc array of name/value pairs
    *
-   * @internal param array $ids the array that holds all the db ids
-   *
-   * @return object CRM_Financial_DAO_PaymentProcessorType
-   * @access public
+   * @return CRM_Financial_DAO_PaymentProcessorType
    * @static
    */
-  static function create($params) {
+  public static function create($params) {
     $job = new CRM_Core_DAO_Job();
     $job->copyValues($params);
     return $job->save();
@@ -70,11 +67,10 @@ class CRM_Core_BAO_Job extends CRM_Core_DAO_Job {
    * @param array $params   (reference ) an assoc array of name/value pairs
    * @param array $defaults (reference ) an assoc array to hold the flattened values
    *
-   * @return object CRM_Core_DAO_Job object on success, null otherwise
-   * @access public
+   * @return CRM_Core_DAO_Job object on success, null otherwise
    * @static
    */
-  static function retrieve(&$params, &$defaults) {
+  public static function retrieve(&$params, &$defaults) {
     $job = new CRM_Core_DAO_Job();
     $job->copyValues($params);
     if ($job->find(TRUE)) {
@@ -85,34 +81,30 @@ class CRM_Core_BAO_Job extends CRM_Core_DAO_Job {
   }
 
   /**
-   * update the is_active flag in the db
+   * Update the is_active flag in the db
    *
    * @param int      $id        id of the database record
    * @param boolean  $is_active value we want to set the is_active field
    *
    * @return Object             DAO object on sucess, null otherwise
    *
-   * @access public
    * @static
    */
-  static function setIsActive($id, $is_active) {
+  public static function setIsActive($id, $is_active) {
     return CRM_Core_DAO::setFieldValue('CRM_Core_DAO_Job', $id, 'is_active', $is_active);
   }
 
   /**
    * Function  to delete scheduled job
    *
-   * @param $jobID
-   *
-   * @internal param int $jobId ID of the job to be deleted.
+   * @param $jobID ID of the job to be deleted.
    *
    * @return bool|null
-   * @access public
    * @static
    */
-  static function del($jobID) {
+  public static function del($jobID) {
     if (!$jobID) {
-      CRM_Core_Error::fatal(ts('Invalid value passed to delete function'));
+      CRM_Core_Error::fatal(ts('Invalid value passed to delete function.'));
     }
 
     $dao = new CRM_Core_DAO_Job();
@@ -131,7 +123,7 @@ class CRM_Core_BAO_Job extends CRM_Core_DAO_Job {
    *
    * CRM-10513
    */
-  static function cleanup($maxEntriesToKeep = 1000, $minDaysToKeep = 30) {
+  public static function cleanup($maxEntriesToKeep = 1000, $minDaysToKeep = 30) {
     // Prevent the job log from getting too big
     // For now, keep last minDays days and at least maxEntries records
     $query = 'SELECT COUNT(*) FROM civicrm_job_log';