/** * 获取实例 * * @return Bll_House_UpDown_RedisQueueBll */ public static function get_instance() { if (is_null(self::$instance)) { self::$instance = new self(); } return self::$instance; }
/** * 初始化 */ public function init() { // Per [--per=10](指定每轮处理的记录数目) $this->per = (int) $this->getOption('per', 100); if ($this->per < 10 || $this->per > 1000) { throw new Exception('Invalid option "per": 10 <= per <= 1000'); } $this->cursor = Bll_House_UpDown_HouseToSolrCursorBll::get_instance(); }