libs: Remove unused deprecated BufferingStatsdDataFactory::getBuffer()
[lhc/web/wiklou.git] / includes / libs / stats / BufferingStatsdDataFactory.php
index d75d9c0..679b1c3 100644 (file)
@@ -91,35 +91,26 @@ class BufferingStatsdDataFactory extends StatsdDataFactory implements IBuffering
                return $entity;
        }
 
-       /**
-        * @deprecated Use getData()
-        * @return StatsdData[]
-        */
-       public function getBuffer() {
-               return $this->buffer;
-       }
-
-       /**
-        * Check whether this data factory has any data.
-        * @return bool
-        */
        public function hasData() {
                return !empty( $this->buffer );
        }
 
        /**
-        * Return data from the factory.
+        * @since 1.30
         * @return StatsdData[]
         */
        public function getData() {
                return $this->buffer;
        }
 
-       /**
-        * Set collection enable status.
-        * @param bool $enabled Will collection be enabled?
-        * @return void
-        */
+       public function clearData() {
+               $this->buffer = [];
+       }
+
+       public function getDataCount() {
+               return count( $this->buffer );
+       }
+
        public function setEnabled( $enabled ) {
                $this->enabled = $enabled;
        }