Identifier.class.php

Go to the documentation of this file.
00001 <?php
00002 /***************************************************************************
00003  *   Copyright (C) 2005-2007 by Garmonbozia Research Group                 *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU Lesser General Public License as        *
00007  *   published by the Free Software Foundation; either version 3 of the    *
00008  *   License, or (at your option) any later version.                       *
00009  *                                                                         *
00010  ***************************************************************************/
00011 /* $Id: Identifier.class.php 4687 2007-12-09 18:57:18Z voxus $ */
00012 
00019     final class Identifier implements Identifiable
00020     {
00021         private $id     = null;
00022         private $final  = false;
00023         
00027         public static function create()
00028         {
00029             return new self;
00030         }
00031         
00035         public static function wrap($id)
00036         {
00037             return self::create()->setId($id);
00038         }
00039         
00040         public function getId()
00041         {
00042             return $this->id;
00043         }
00044         
00048         public function setId($id)
00049         {
00050             $this->id = $id;
00051             
00052             return $this;
00053         }
00054         
00058         public function finalize()
00059         {
00060             $this->final = true;
00061             
00062             return $this;
00063         }
00064         
00065         public function isFinalized()
00066         {
00067             return $this->final;
00068         }
00069     }
00070 ?>

Generated on Sun Dec 9 21:56:22 2007 for onPHP by  doxygen 1.5.4