3 * Table Definition for user_openid
5 require_once INSTALLDIR.'/classes/Memcached_DataObject.php';
7 class User_openid extends Memcached_DataObject
10 /* the code below is auto generated do not remove the above tag */
12 public $__table = 'user_openid'; // table name
13 public $canonical; // varchar(255) primary_key not_null
14 public $display; // varchar(255) unique_key not_null
15 public $user_id; // int(4) not_null
16 public $created; // datetime() not_null
17 public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP
20 function staticGet($k,$v=null)
21 { return Memcached_DataObject::staticGet('User_openid',$k,$v); }
23 /* the code above is auto generated do not remove the tag below */
29 $db = $this->getDatabaseConnection();
30 $dbtype = $db->phptype; // Database type is stored here. Crazy but true.
32 return array('canonical' => DB_DATAOBJECT_STR + DB_DATAOBJECT_NOTNULL,
33 'display' => DB_DATAOBJECT_STR + DB_DATAOBJECT_NOTNULL,
34 'user_id' => DB_DATAOBJECT_INT + DB_DATAOBJECT_NOTNULL,
35 'created' => DB_DATAOBJECT_STR + DB_DATAOBJECT_DATE + DB_DATAOBJECT_TIME + DB_DATAOBJECT_NOTNULL,
36 'modified' => ($dbtype == 'mysql' || $dbtype == 'mysqli') ?
37 DB_DATAOBJECT_MYSQLTIMESTAMP + DB_DATAOBJECT_NOTNULL :
38 DB_DATAOBJECT_STR + DB_DATAOBJECT_DATE + DB_DATAOBJECT_TIME
44 return array('canonical' => 'K', 'display' => 'U');
47 Static function hasOpenID($user_id)
49 $oid = new User_openid();
51 $oid->user_id = $user_id;