Merge branch 'angular-tests' of https://github.com/giant-rabbit/civicrm-core into...
[civicrm-core.git] / CRM / Mailing / MailStore / Localdir.php
index 5dec460d9d012f73d27a4b8880d4c609f5107f30..0fc7d476e4ad28f6e7abd83198c5447af4a9838d 100644 (file)
@@ -1,7 +1,7 @@
 <?php
 /*
  +--------------------------------------------------------------------+
- | CiviCRM version 4.5                                                |
+ | CiviCRM version 4.6                                                |
  +--------------------------------------------------------------------+
  | Copyright CiviCRM LLC (c) 2004-2014                                |
  +--------------------------------------------------------------------+
 
 require_once 'ezc/Base/src/ezc_bootstrap.php';
 require_once 'ezc/autoload/mail_autoload.php';
+
+/**
+ * Class CRM_Mailing_MailStore_Localdir
+ */
 class CRM_Mailing_MailStore_Localdir extends CRM_Mailing_MailStore {
 
   /**
    * Connect to the supplied dir and make sure the two mail dirs exist
    *
-   * @param string $dir  dir to operate upon
+   * @param string $dir dir to operate upon
    *
-   * @return void
+   * @return \CRM_Mailing_MailStore_Localdir
    */
-  function __construct($dir) {
+  public function __construct($dir) {
     $this->_dir = $dir;
 
     $this->_ignored = $this->maildir(implode(DIRECTORY_SEPARATOR, array('CiviMail.ignored', date('Y'), date('m'), date('d'))));
@@ -59,7 +63,7 @@ class CRM_Mailing_MailStore_Localdir extends CRM_Mailing_MailStore {
    *
    * @return array      array of ezcMail objects
    */
-  function fetchNext($count = 0) {
+  public function fetchNext($count = 0) {
     $mails = array();
     $path = rtrim($this->_dir, DIRECTORY_SEPARATOR);
 
@@ -109,11 +113,12 @@ class CRM_Mailing_MailStore_Localdir extends CRM_Mailing_MailStore {
   /**
    * Fetch the specified message to the local ignore folder
    *
-   * @param integer $file  file location of the message to fetch
+   * @param integer $file file location of the message to fetch
    *
+   * @throws Exception
    * @return void
    */
-  function markIgnored($file) {
+  public function markIgnored($file) {
     if ($this->_debug) {
       print "moving $file to ignored folder\n";
     }
@@ -126,11 +131,12 @@ class CRM_Mailing_MailStore_Localdir extends CRM_Mailing_MailStore {
   /**
    * Fetch the specified message to the local processed folder
    *
-   * @param integer $file  file location of the message to fetch
+   * @param integer $file file location of the message to fetch
    *
+   * @throws Exception
    * @return void
    */
-  function markProcessed($file) {
+  public function markProcessed($file) {
     if ($this->_debug) {
       print "moving $file to processed folder\n";
     }
@@ -140,4 +146,3 @@ class CRM_Mailing_MailStore_Localdir extends CRM_Mailing_MailStore {
     }
   }
 }
-