<commit_before><?php
/**
 * Created by PhpStorm.
 * User: robbie
 * Date: 4/18/15
 * Time: 1:52 PM
 */

namespace PHPServices;


class StringOperations
{
    public function replace($find, $replace, $string)
    {
        $newString = str_replace($find, $replace, $string);
        return $newString;<commit_msg>Added lowercase and firstCharacter methods to StringOperations<commit_after><?php
/**
 * Created by PhpStorm.
 * User: robbie
 * Date: 4/18/15
 * Time: 1:52 PM
 */

namespace PHPServices;


class StringOperations
{
    public function lowercase($string)
    {
        return strtolower($string);
    }

    public function firstCharacter($string)
    {
        return $string[0];
    }

    public function replace($find, $replace, $string)
    {
        $newString = str_replace($find, $replace, $string);
        return $newString;
{'fraction_non_alphanumeric': 0.12307692307692308, 'fraction_numerical': 0.020118343195266272, 'mean_word_length': 3.126829268292683, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 3, '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': '4994930', 'n_tokens_mistral': 275, 'n_tokens_neox': 264, 'n_words': 67}