<commit_before><?php

namespace PiPHP\GPIO\FileSystem;

interface FileSystemInterface
{
    /**
     * Open a file for reading or writing.
     * 
     * @param string $path The path of the file to open
     * @param string $mode The mode to open the file in (see fopen())
     * 
     * @return StreamInterface
     */
    public function open($path, $mode);
}<commit_msg>Update FileSystemInterface.php<commit_after><?php

namespace PiPHP\GPIO\FileSystem;

interface FileSystemInterface
{
    /**
     * Read the contents of a file.
     * 
     * @param string $path The path of the file to read
     * 
     * @return string The file contents
     */
    public function getContents($path);

    /**
     * Write a buffer to a file.
     * 
     * @param string $path   The path of the file to write to
     * @param string $buffer The buffer to write
     * @param int    $flags  Optional flags, as per the documentation of file_put_contents()
     * 
     * @return int The number of bytes written
     */
    public function putContents($path, $buffer, $flags = 0);
}
{'fraction_non_alphanumeric': 0.09133271202236719, 'fraction_numerical': 0.0009319664492078285, 'mean_word_length': 2.5098039215686274, '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': '6873300', 'n_tokens_mistral': 308, 'n_tokens_neox': 300, 'n_words': 118}