Merge "Read full memcached response before manipulating data"
[lhc/web/wiklou.git] / includes / filebackend / filejournal / FileJournal.php
index d99384d..b0f39c3 100644 (file)
@@ -125,6 +125,23 @@ abstract class FileJournal {
         */
        abstract protected function doGetCurrentPosition();
 
+       /**
+        * Get the position ID of the latest journal entry at some point in time
+        *
+        * @param $time integer|string timestamp
+        * @return integer|false
+        */
+       final public function getPositionAtTime( $time ) {
+               return $this->doGetPositionAtTime( $time );
+       }
+
+       /**
+        * @see FileJournal::getPositionAtTime()
+        * @param $time integer|string timestamp
+        * @return integer|false
+        */
+       abstract protected function doGetPositionAtTime( $time );
+
        /**
         * Get an array of file change log entries.
         * A starting change ID and/or limit can be specified.
@@ -201,6 +218,15 @@ class NullFileJournal extends FileJournal {
                return false;
        }
 
+       /**
+        * @see FileJournal::doGetPositionAtTime()
+        * @param $time integer|string timestamp
+        * @return integer|false
+        */
+       protected function doGetPositionAtTime( $time ) {
+               return false;
+       }
+
        /**
         * @see FileJournal::doGetChangeEntries()
         * @return Array