Select Git revision
StructuralElementsImageUpload.php
Forked from
Stud.IP / Stud.IP
Source project has a limited visibility.
-
Marcus Eibrink-Lunzenauer authored
Fixes #142.
Marcus Eibrink-Lunzenauer authoredFixes #142.
Code owners
Assign users and groups as approvers for specific file changes. Learn more.
SimpleORMap.class.php 87.23 KiB
<?php
/**
* SimpleORMap.class.php
* simple object-relational mapping
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of
* the License, or (at your option) any later version.
*
* @author André Noack <noack@data-quest.de>
* @copyright 2010 Stud.IP Core-Group
* @license http://www.gnu.org/licenses/gpl-2.0.html GPL version 2
* @category Stud.IP
*/
class SimpleORMap implements ArrayAccess, Countable, IteratorAggregate
{
/**
* Defines `_` as character used when joining composite primary keys.
*/
const ID_SEPARATOR = '_';
/**
* table row data
* @var array $content
*/
protected $content = [];
/**
* table row data
* @var array $content_db
*/
protected $content_db = [];
/**
* new state of entry
* @var boolean $is_new
*/
protected $is_new = true;
/**
* deleted state of entry
* @var boolean $is_deleted
*/
protected $is_deleted = false;
/**
* db table metadata
* @var ?array $schemes;
*/
public static $schemes = null;
/**
* configuration data for subclasses
* @see self::configure()
* @var array $config;
*/
protected static $config = [];
/**
* stores instantiated related objects
* @var array $relations
*/
protected $relations = [];
/**
* assoc array for storing values for additional fields
*
* @var array $additional_data