Skip to content

Instantly share code, notes, and snippets.

@patrickhafner
Created July 2, 2012 14:47
Show Gist options
  • Save patrickhafner/f4b8efaac83200454cb6 to your computer and use it in GitHub Desktop.
Save patrickhafner/f4b8efaac83200454cb6 to your computer and use it in GitHub Desktop.
Extbase TYPO3 news model
<?php
class Tx_Simplenews_Domain_Model_News extends Tx_Extbase_DomainObject_AbstractEntity {
/**
* @var string
**/
protected $title = '';
/**
* @var Tx_Extbase_Persistence_ObjectStorage<Tx_Simplenews_Domain_Model_Author>
* @lazy
* @cascade remove
**/
protected $author = 0;
/**
* @var DateTime
**/
protected $date = 0;
/**
* @var string
**/
protected $text = '';
public function __construct($title = '', $author = 0, $date = 0, $text = '') {
}
public function getTitle() {
return $this->title;
}
public function setTitle($title) {
$this->title = $title;
}
public function getAuthor() {
return $this->author;
}
public function setAuthor($author) {
$this->author = $author;
}
public function getDate() {
return $this->date;
}
public function setDate($date) {
$this->date = $date;
}
public function getText() {
return $this->text;
}
public function setText($text) {
$this->text = $text;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment