<commit_before><?php

/**
 * This file is part of the Rainbow package.
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 *
 * @license MIT License
 */

namespace Rainbow;

use Rainbow\Unit\Alpha;
use Rainbow\Unit\Percent;
use Rainbow\Translator\Translator;

interface ColorInterface
{
    /**
     * String representation of the color
     * @return string
     */
    public function __toString();

    /**
     * Name of the color
     * @return string
     */
    public function getName();

    /**
     * Extract the alpha channel
     * @return Alpha
     */
    public function getAlpha();

    /**
     * Translator object to convert the color space
     * @return Translator
     */
    public function getTranslator();

    /**
     * Create a copy of the color
     * @return ColorInterface
     */
    public function copy();

    /**
     * Convert to RGB color space
     * @return Rgb
     */
    //public function toRgb();

    /**
     * Convert to HSL color space
     * @return Hsl
     */
    //public function toHsl();

    /**
     * Convert to the indicated color space
     * @param string $colorName  Expected color name
     * @return ColorInterface
     */
    //public function to($colorName);

    /**
     * Calculates the relative luminance of a color in the RGB color space
     * @return Percent
     * @url http://www.w3.org/TR/2008/REC-WCAG20-20081211/#relativeluminancedef
     */
    public function luminance();

    /**
     * Increase the saturation of a color in the HSL color space
     * @param number|string $percentage  A percentage
     * @return ColorInterface
     */
    public function saturate($percentage);

    /**
     * Decrease the saturation of a color in the HSL color space
     * @param number|string $percentage  A percentage
     * @return ColorInterface
     */
    public function desaturate($percentage);

    /**
     * Increase the lightness of a color in the HSL color space
     * @param number|string $percentage  A percentage
     * @return ColorInterface
     */<commit_msg>Remove deprecated method definitions from interface<commit_after><?php

/**
 * This file is part of the Rainbow package.
 * For the full copyright and license information, please view the LICENSE
 * file that was distributed with this source code.
 *
 * @license MIT License
 */

namespace Rainbow;

use Rainbow\Unit\Alpha;
use Rainbow\Unit\Percent;
use Rainbow\Translator\Translator;

interface ColorInterface
{
    /**
     * String representation of the color
     * @return string
     */
    public function __toString();

    /**
     * Name of the color
     * @return string
     */
    public function getName();

    /**
     * Extract the alpha channel
     * @return Alpha
     */
    public function getAlpha();

    /**
     * Translator object to convert the color space
     * @return Translator
     */
    public function getTranslator();

    /**
     * Create a copy of the color
     * @return ColorInterface
     */
    public function copy();

    /**
     * Calculates the relative luminance of a color in the RGB color space
     * @return Percent
     * @url http://www.w3.org/TR/2008/REC-WCAG20-20081211/#relativeluminancedef
     */
    public function luminance();

    /**
     * Increase the saturation of a color in the HSL color space
     * @param number|string $percentage  A percentage
     * @return ColorInterface
     */
    public function saturate($percentage);

    /**
     * Decrease the saturation of a color in the HSL color space
     * @param number|string $percentage  A percentage
     * @return ColorInterface
     */
    public function desaturate($percentage);

    /**
     * Increase the lightness of a color in the HSL color space
     * @param number|string $percentage  A percentage
     * @return ColorInterface
     */
{'fraction_non_alphanumeric': 0.08995386981035366, 'fraction_numerical': 0.007688364941055869, 'mean_word_length': 2.405759162303665, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, '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': '4015696', 'n_tokens_mistral': 1106, 'n_tokens_neox': 1027, 'n_words': 384}