<commit_before><?php
namespace Jasny\DB;

/**
 * Interface for the active record design pattern
 * 
 * @author  <NAME> <<EMAIL>>
 * @license https://raw.github.com/jasny/db/master/LICENSE MIT
 * @link    https://jasny.github.com/db
 */
interface ActiveRecord extends Deletable
{
    /**
     * Fetch a single entity.
     * 
     * @param string|array $filter  ID or filter
     * @return static
     */
    public static function fetch($filter);
    
    /**
     * Check if an entity exists
     * 
     * @param string|array $filter  ID or filter
     * @return boolean
     */
    public static function exists($filter);

    /**
     * Save the entity
     * 
     * @return $this
     */
    public function save();
}<commit_msg>Added AciveRecord::delete()<commit_after><?php
namespace Jasny\DB;

/**
 * Interface for the active record design pattern
 * 
 * @author  <NAME> <<EMAIL>>
 * @license https://raw.github.com/jasny/db/master/LICENSE MIT
 * @link    https://jasny.github.com/db
 */
interface ActiveRecord
{
    /**
     * Fetch a single entity.
     * 
     * @param string|array $filter  ID or filter
     * @return static
     */
    public static function fetch($filter);
    
    /**
     * Check if an entity exists in the database.
     * 
     * @param string|array $filter  ID or filter
     * @return boolean
     */
    public static function exists($filter);

    /**
     * Save the entity to the database.
     * 
     * @return $this
     */
    public function save();

    /**
     * Delete the entity from the database.
     * 
     * @return $this
     */
    public function delete();
}
{'fraction_non_alphanumeric': 0.12469135802469136, 'fraction_numerical': 0.0, 'mean_word_length': 2.159844054580897, 'pattern_counts': {'":': 0, '<': 11, '<?xml version=': 0, '>': 9, 'https://': 4, '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': '3687041', 'n_tokens_mistral': 489, 'n_tokens_neox': 475, 'n_words': 142}