+ public static function schemaDef()
+ {
+ return array(
+ 'description' => 'Hash tags',
+ 'fields' => array(
+ 'tag' => array('type' => 'varchar', 'length' => 64, 'not null' => true, 'description' => 'hash tag associated with this notice'),
+ 'notice_id' => array('type' => 'int', 'not null' => true, 'description' => 'notice tagged'),
+ 'created' => array('type' => 'datetime', 'not null' => true, 'description' => 'date this record was created'),
+ ),
+ 'primary key' => array('tag', 'notice_id'),
+ 'foreign keys' => array(
+ 'notice_tag_notice_id_fkey' => array('notice', array('notice_id' => 'id')),
+ ),
+ 'indexes' => array(
+ 'notice_tag_created_idx' => array('created'),
+ 'notice_tag_notice_id_idx' => array('notice_id'),
+ 'notice_tag_tag_created_notice_id_idx' => array('tag', 'created', 'notice_id')
+ ),
+ );
+ }
+