PHP Classes

File: tests/Model/InvalidReferenceModel.php

Recommend this page to a friend!
  Classes of Maik Greubel   Caribu ORM   tests/Model/InvalidReferenceModel.php   Download  
File: tests/Model/InvalidReferenceModel.php
Role: Unit test script
Content type: text/plain
Description: Testing model for invalid mapping
Class: Caribu ORM
Map objects to databases records using annotations
Author: By
Last change: Strong type and documentation fixes
Date: 7 years ago
Size: 1,354 bytes
 

Contents

Class file image Download
<?php
namespace Nkey\Caribu\Tests\Model;

use
Nkey\Caribu\Model\AbstractModel;

/**
 *
 * @author Maik Greubel <greubel@nkey.de>
 *
 * @table blog
 * @eager
 */
class InvalidReferenceModel extends AbstractModel
{
   
/**
     * @id
     */
   
private $id;

   
/**
     * @var string
     * @column content
     */
   
private $content;

   
/**
     * This referenced class does not exist!
     *
     * @var Poster
     *
     * @mappedBy(table=blog_user_to_posts,column=userid,inverseColumn=postid)
     */
   
private $poster;

   
/**
     *
     * @return int
     */
   
public function getId()
    {
        return
$this->id;
    }

   
/**
     *
     * @param int $id
     */
   
public function setId($id)
    {
       
$this->id = $id;
        return
$this;
    }

   
/**
     *
     * @return string
     */
   
public function getContent()
    {
        return
$this->content;
    }

   
/**
     *
     * @param string $content
     */
   
public function setContent($content)
    {
       
$this->content = $content;
        return
$this;
    }

   
/**
     *
     * @return Poster
     */
   
public function getPoster()
    {
        return
$this->poster;
    }

   
/**
     *
     * @param
     * $poster
     */
   
public function setPoster($poster)
    {
       
$this->poster = $poster;
        return
$this;
    }
}