1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253 |
- <?php
- require_once INSTALLDIR.'/classes/Memcached_DataObject.php';
- class Nonce extends Managed_DataObject
- {
-
-
- public $__table = 'nonce';
- public $consumer_key;
- public $tok;
- public $nonce;
- public $ts;
- public $created;
- public $modified;
-
-
-
- function links()
- {
- return array('consumer_key,token' => 'token:consumer_key,token');
- }
- public static function schemaDef()
- {
- return array(
- 'description' => 'OAuth nonce record',
- 'fields' => array(
- 'consumer_key' => array('type' => 'varchar', 'length' => 191, 'not null' => true, 'description' => 'unique identifier, root URL'),
- 'tok' => array('type' => 'char', 'length' => 32, 'description' => 'buggy old value, ignored'),
- 'nonce' => array('type' => 'char', 'length' => 32, 'not null' => true, 'description' => 'nonce'),
- 'ts' => array('type' => 'datetime', 'not null' => true, 'description' => 'timestamp sent'),
- 'created' => array('type' => 'datetime', 'not null' => true, 'default' => '0000-00-00 00:00:00', 'description' => 'date this record was created'),
- 'modified' => array('type' => 'datetime', 'not null' => true, 'default' => 'CURRENT_TIMESTAMP', 'description' => 'date this record was modified'),
- ),
- 'primary key' => array('consumer_key', 'ts', 'nonce'),
- );
- }
- }
|