/apps/todo/domain/TodoListItem.php

http://zoop.googlecode.com/ · PHP · 26 lines · 23 code · 3 blank · 0 comment · 1 complexity · 8284c1567097bfa46fdcf69d483ceaad MD5 · raw file

  1. <?php
  2. class TodoListItem
  3. {
  4. var $parent;
  5. var $children;
  6. var $text;
  7. var $status;
  8. var $importance;
  9. var $urgency;
  10. function TodoListItem(&$parent, $status, $text, $params = NULL)
  11. {
  12. $this->children = array();
  13. $this->parent = &$parent;
  14. if($parent)
  15. $parent->addChild($this);
  16. $this->status = $status;
  17. $this->text = $text;
  18. }
  19. function addChild(&$child)
  20. {
  21. $this->children[] = &$child;
  22. }
  23. }