<commit_before># Copyright (c) 2016 The Regents of the University of Michigan
# All rights reserved.
# This software is licensed under the BSD 3-Clause License.
import logging

logger = logging.getLogger(__name__)


class BasicFormat(object):
    pass


class FileFormat(BasicFormat):

    def __init__(self, file_object):
        self._file_object = file_object

    @property
    def data(self):
        return self.read()

    def read(self, size=-1):
        return self._file_object.read(size)

    def seek(self, offset):
        return self._file_object.seek(offset)

    def tell(self):
        return self._file_object.tell()

    def __iter__(self):
        return iter(self._file_object)

    def close(self):
        return self._file_object.close()


class TextFile(FileFormat):
    pass<commit_msg>Replace TextFile class definition with str constant.<commit_after># Copyright (c) 2016 The Regents of the University of Michigan
# All rights reserved.
# This software is licensed under the BSD 3-Clause License.

TextFile = 'TextFile'
{'fraction_non_alphanumeric': 0.08604206500956023, 'fraction_numerical': 0.010516252390057362, 'mean_word_length': 3.4553191489361703, 'pattern_counts': {'":': 0, '<': 3, '<?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': '3918149', 'n_tokens_mistral': 310, 'n_tokens_neox': 290, 'n_words': 97}