*
* @see DB_DataObject
*/
-
class Sitemap_notice_count extends Memcached_DataObject
{
public $__table = 'sitemap_notice_count'; // table name
* @return Sitemap_notice_count object found, or null for no hits
*
*/
-
function staticGet($k, $v=null)
{
return Memcached_DataObject::staticGet('Sitemap_notice_count', $k, $v);
*
* @return array array of column definitions
*/
-
function table()
{
return array('notice_date' => DB_DATAOBJECT_DATE + DB_DATAOBJECT_NOTNULL,
*
* @return array key definitions
*/
-
function keys()
{
return array('notice_date' => 'K');
*
* @return array key definitions
*/
-
function keyTypes()
{
return $this->keys();
$noticeCounts = self::cacheGet('sitemap:notice:counts');
if ($noticeCounts === false) {
-
$snc = new Sitemap_notice_count();
$snc->orderBy('notice_date DESC');
$snc = Sitemap_notice_count::staticGet('notice_date', DB_DataObject_Cast::date($d));
if (empty($snc)) {
- throw new Exception("No such registration date: $d");
+ // TRANS: Exception
+ throw new Exception(_m("No such registration date: $d."));
}
$orig = clone($snc);