From 2ed073f2956ded804e39a9259408ac59ca46189f Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Tue, 15 Sep 2009 18:28:44 -0400 Subject: new data structures for location --- classes/Location_namespace.php | 46 ++++++++++++++++++++++++++++++++++++++++++ classes/Notice.php | 8 +++++++- classes/Profile.php | 8 +++++++- 3 files changed, 60 insertions(+), 2 deletions(-) create mode 100755 classes/Location_namespace.php diff --git a/classes/Location_namespace.php b/classes/Location_namespace.php new file mode 100755 index 000000000..5ab95d9ef --- /dev/null +++ b/classes/Location_namespace.php @@ -0,0 +1,46 @@ +. + */ + +if (!defined('STATUSNET') && !defined('LACONICA')) { exit(1); } + +/** + * Table Definition for location_namespace + */ + +require_once INSTALLDIR.'/classes/Memcached_DataObject.php'; + +class Location_namespace extends Memcached_DataObject +{ + ###START_AUTOCODE + /* the code below is auto generated do not remove the above tag */ + + public $__table = 'location_namespace'; // table name + public $id; // int(4) primary_key not_null + public $description; // varchar(255) + public $created; // datetime() not_null + public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP + + /* Static get */ + function staticGet($k,$v=NULL) { + return Memcached_DataObject::staticGet('Location_namespace',$k,$v); + } + + /* the code above is auto generated do not remove the tag below */ + ###END_AUTOCODE +} diff --git a/classes/Notice.php b/classes/Notice.php index cd3906ca1..592f64426 100644 --- a/classes/Notice.php +++ b/classes/Notice.php @@ -66,9 +66,15 @@ class Notice extends Memcached_DataObject public $is_local; // tinyint(1) public $source; // varchar(32) public $conversation; // int(4) + public $lat; // decimal(10,7) + public $lon; // decimal(10,7) + public $location_id; // int(4) + public $location_ns; // int(4) /* Static get */ - function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Notice',$k,$v); } + function staticGet($k,$v=NULL) { + return Memcached_DataObject::staticGet('Notice',$k,$v); + } /* the code above is auto generated do not remove the tag below */ ###END_AUTOCODE diff --git a/classes/Profile.php b/classes/Profile.php index 4a069ee84..5fb7bb678 100644 --- a/classes/Profile.php +++ b/classes/Profile.php @@ -37,11 +37,17 @@ class Profile extends Memcached_DataObject public $homepage; // varchar(255) multiple_key public $bio; // text() multiple_key public $location; // varchar(255) multiple_key + public $lat; // decimal(10,7) + public $lon; // decimal(10,7) + public $location_id; // int(4) + public $location_ns; // int(4) public $created; // datetime() not_null public $modified; // timestamp() not_null default_CURRENT_TIMESTAMP /* Static get */ - function staticGet($k,$v=NULL) { return Memcached_DataObject::staticGet('Profile',$k,$v); } + function staticGet($k,$v=NULL) { + return Memcached_DataObject::staticGet('Profile',$k,$v); + } /* the code above is auto generated do not remove the tag below */ ###END_AUTOCODE -- cgit v1.2.3-54-g00ecf