diff options
Diffstat (limited to 'plugins/jetpack/modules/sitemaps/sitemap-buffer-master.php')
-rw-r--r-- | plugins/jetpack/modules/sitemaps/sitemap-buffer-master.php | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/plugins/jetpack/modules/sitemaps/sitemap-buffer-master.php b/plugins/jetpack/modules/sitemaps/sitemap-buffer-master.php index 09d18c35..cd5359f2 100644 --- a/plugins/jetpack/modules/sitemaps/sitemap-buffer-master.php +++ b/plugins/jetpack/modules/sitemaps/sitemap-buffer-master.php @@ -1,4 +1,5 @@ -<?php +<?php // phpcs:ignore WordPress.Files.FileName.InvalidClassFileName +// phpcs:disable Generic.Classes.DuplicateClassName.Found -- sitemap-builder.php will require correct class file. /** * Sitemaps (per the protocol) are essentially lists of XML fragments; * lists which are subject to size constraints. The Jetpack_Sitemap_Buffer_Master @@ -15,7 +16,13 @@ * @since 5.3.0 */ class Jetpack_Sitemap_Buffer_Master extends Jetpack_Sitemap_Buffer { - + /** + * Jetpack_Sitemap_Buffer_Master constructor. + * + * @param int $item_limit The maximum size of the buffer in items. + * @param int $byte_limit The maximum size of the buffer in bytes. + * @param string $time The initial datetime of the buffer. Must be in 'YYYY-MM-DD hh:mm:ss' format. + */ public function __construct( $item_limit, $byte_limit, $time = '1970-01-01 00:00:00' ) { parent::__construct( $item_limit, $byte_limit, $time ); @@ -31,6 +38,9 @@ class Jetpack_Sitemap_Buffer_Master extends Jetpack_Sitemap_Buffer { ); } + /** + * Returns a DOM element that contains all master sitemap elements. + */ protected function get_root_element() { if ( ! isset( $this->root ) ) { $this->root = $this->doc->createElement( 'sitemapindex' ); |