- /* Static get */
- function staticGet($k,$v=null)
- { return Memcached_DataObject::staticGet('Profile_tag',$k,$v); }
-
- /* the code above is auto generated do not remove the tag below */
- ###END_AUTOCODE
-
- function pkeyGet($kv) {
- return Memcached_DataObject::pkeyGet('Profile_tag', $kv);
+ public static function schemaDef()
+ {
+ return array(
+
+ 'fields' => array(
+ 'tagger' => array('type' => 'int', 'not null' => true, 'description' => 'user making the tag'),
+ 'tagged' => array('type' => 'int', 'not null' => true, 'description' => 'profile tagged'),
+ 'tag' => array('type' => 'varchar', 'length' => 64, 'not null' => true, 'description' => 'hash tag associated with this notice'),
+ 'modified' => array('type' => 'timestamp', 'not null' => true, 'description' => 'date the tag was added'),
+ ),
+ 'primary key' => array('tagger', 'tagged', 'tag'),
+ 'foreign keys' => array(
+ 'profile_tag_tagger_fkey' => array('profile', array('tagger' => 'id')),
+ 'profile_tag_tagged_fkey' => array('profile', array('tagged' => 'id')),
+ 'profile_tag_tag_fkey' => array('profile_list', array('tag' => 'tag')),
+ ),
+ 'indexes' => array(
+ 'profile_tag_modified_idx' => array('modified'),
+ 'profile_tag_tagger_tag_idx' => array('tagger', 'tag'),
+ 'profile_tag_tagged_idx' => array('tagged'),
+ ),
+ );