MediaWiki master
JSONRCFeedFormatter.php
Go to the documentation of this file.
1<?php
2
22namespace MediaWiki\RCFeed;
23
25
38
39 protected function formatArray( array $packet ) {
40 return FormatJson::encode( $packet );
41 }
42}
44class_alias( JSONRCFeedFormatter::class, 'JSONRCFeedFormatter' );
JSON formatter wrapper class.
Format a recent change notification using JSON (https://www.json.org).
formatArray(array $packet)
Take the packet and return the formatted string.
Abstract class so there can be multiple formatters outputting the same data.