wiki.techinc.nl/includes/libs/Stats/IBufferingStatsdDataFactory.php
James D. Forrester cc28acc455 Add namespace to remaining parts of Wikimedia\Mime and Wikimedia\Stats
Bug: T353458
Change-Id: If0137003ab625017d322d57870448a02569668c3
2024-09-27 16:19:10 -04:00

50 lines
1.1 KiB
PHP

<?php
namespace Wikimedia\Stats;
use Liuggio\StatsdClient\Entity\StatsdData;
use Liuggio\StatsdClient\Factory\StatsdDataFactoryInterface;
/**
* MediaWiki adaptation of StatsdDataFactory that provides buffering functionality.
*
* @stable to implement
* @since 1.30
* @see BufferingStatsdDataFactory
*/
interface IBufferingStatsdDataFactory extends StatsdDataFactoryInterface {
/**
* Check whether this data factory has any buffered data.
* @return bool
*/
public function hasData();
/**
* Return the buffered data from the factory.
* @return StatsdData[]
*/
public function getData();
/**
* Clear all buffered data from the factory
* @since 1.31
*/
public function clearData();
/**
* Return the number of buffered statsd data entries
* @return int
* @since 1.31
*/
public function getDataCount();
/**
* Set collection enable status.
* @param bool $enabled Will collection be enabled?
* @return void
*/
public function setEnabled( $enabled );
}
/** @deprecated class alias since 1.43 */
class_alias( IBufferingStatsdDataFactory::class, 'IBufferingStatsdDataFactory' );