<commit_before><?php
if ( !class_exists('Puc_v4p9_Factory', false) ):

	/**
	 * A factory that builds update checker instances.
	 *
	 * When multiple versions of the same class have been loaded (e.g. PluginUpdateChecker 4.0
	 * and 4.1), this factory will always use the latest available minor version. Register class
	 * versions by calling {@link PucFactory::addVersion()}.
	 *
	 * At the moment it can only build instances of the UpdateChecker class. Other classes are
	 * intended mainly for internal use and refer directly to specific implementations.
	 */
	class Puc_v4p9_Factory {
		protected static $classVersions = array();
		protected static $sorted = false;

		protected static $myMajorVersion = '';
		protected static $latestCompatibleVersion = '';

		/**
		 * Wrapper method for buildUpdateChecker.
		 *
		 * @param string $fullPath
		 * @param array
		 */
		public static function updateChecker( $fullPath, $args = array() ) {
			$fullPath = self::normalizePath( $fullPath );

			//Set up defaults.
			$defaults = array(
				'metadataUrl'  => '',
				'slug'         => '',
				'checkPeriod'  => 12,
				'optionName'   => '',
				'muPluginFile' => '',
			);
			$args = array_merge( $defaults, array_intersect_key( $args, $defaults ) );
			extract( $args );

			//Check for the service URI
			if ( empty( $metadataUrl ) ) {
				$metadataUrl = self::getServiceURI( $fullPath );
			}

			return self::buildUpdateChecker( $metadataUrl, $fullPath, $slug, $checkPeriod, $optionName, $muPluginFile );
		}

		/**
		 * Create a new instance of the update checker.
		 *
		 * This method automatically detects if you're using it for a plugin or a theme and chooses
		 * the appropriate implementation for your update source (JSON file, GitHub, BitBucket, etc).<commit_msg>change method name, add EXTR_SKIP to extract call<commit_after><?php
if ( !class_exists('Puc_v4p9_Factory', false) ):

	/**
	 * A factory that builds update checker instances.
	 *
	 * When multiple versions of the same class have been loaded (e.g. PluginUpdateChecker 4.0
	 * and 4.1), this factory will always use the latest available minor version. Register class
	 * versions by calling {@link PucFactory::addVersion()}.
	 *
	 * At the moment it can only build instances of the UpdateChecker class. Other classes are
	 * intended mainly for internal use and refer directly to specific implementations.
	 */
	class Puc_v4p9_Factory {
		protected static $classVersions = array();
		protected static $sorted = false;

		protected static $myMajorVersion = '';
		protected static $latestCompatibleVersion = '';

		/**
		 * Wrapper method for buildUpdateChecker.
		 *
		 * @param string $fullPath
		 * @param array
		 */
		public static function buildFromHeader( $fullPath, $args = array() ) {
			$fullPath = self::normalizePath( $fullPath );

			//Set up defaults.
			$defaults = array(
				'metadataUrl'  => '',
				'slug'         => '',
				'checkPeriod'  => 12,
				'optionName'   => '',
				'muPluginFile' => '',
			);
			$args = array_merge( $defaults, array_intersect_key( $args, $defaults ) );
			extract( $args, EXTR_SKIP );

			//Check for the service URI
			if ( empty( $metadataUrl ) ) {
				$metadataUrl = self::getServiceURI( $fullPath );
			}

			return self::buildUpdateChecker( $metadataUrl, $fullPath, $slug, $checkPeriod, $optionName, $muPluginFile );
		}

		/**
		 * Create a new instance of the update checker.
		 *
		 * This method automatically detects if you're using it for a plugin or a theme and chooses
		 * the appropriate implementation for your update source (JSON file, GitHub, BitBucket, etc).
{'fraction_non_alphanumeric': 0.11231581873783708, 'fraction_numerical': 0.005560189046427579, 'mean_word_length': 3.5144291091593476, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 13, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1507022', 'n_tokens_mistral': 1176, 'n_tokens_neox': 1010, 'n_words': 363}