Entity.php 539 B

123456789101112131415161718192021222324252627
  1. <?php
  2. /**
  3. * Entity superclass.
  4. *
  5. * Every other entity must inherit from this one. It represents a database
  6. * entity.
  7. */
  8. abstract class Entity{
  9. /**
  10. * Database connection.
  11. */
  12. public $db;
  13. /**
  14. * Constructor.
  15. *
  16. * Sets the database conection and the language.
  17. *
  18. * @param MySQL_connection $db Connection to the database.
  19. */
  20. public function __construct($db){
  21. $this->db = $db;
  22. }
  23. }
  24. ?>