本文整理匯總了PHP中SearchResult::opo_locales方法的典型用法代碼示例。如果您正苦於以下問題:PHP SearchResult::opo_locales方法的具體用法?PHP SearchResult::opo_locales怎麽用?PHP SearchResult::opo_locales使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類SearchResult
的用法示例。
在下文中一共展示了SearchResult::opo_locales方法的1個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: __construct
public function __construct($po_engine_result = null, $pa_tables = null)
{
if (!SearchResult::$opo_datamodel) {
SearchResult::$opo_datamodel = Datamodel::load();
}
$this->opo_db = SearchResult::$o_db ? SearchResult::$o_db : (SearchResult::$o_db = new Db());
$this->opo_subject_instance = SearchResult::$opo_datamodel->getInstanceByTableName($this->ops_table_name, true);
$this->ops_subject_pk = $this->opo_subject_instance->primaryKey();
$this->ops_subject_idno = $this->opo_subject_instance->getProperty('ID_NUMBERING_ID_FIELD');
$this->opb_use_identifiers_in_urls = (bool) $this->opo_subject_instance->getAppConfig()->get('use_identifiers_in_urls');
$this->opa_row_ids_to_prefetch_cache = array();
if (!SearchResult::$opo_locales) {
SearchResult::$opo_locales = new ca_locales();
}
if (!SearchResult::$opa_locales) {
SearchResult::$opa_locales = ca_locales::getLocaleList();
}
if (!SearchResult::$opt_list) {
SearchResult::$opt_list = SearchResult::$opo_datamodel->getInstanceByTableName('ca_lists', true);
}
if ($po_engine_result) {
$this->init($po_engine_result, $pa_tables);
}
if (!$GLOBALS["_DbResult_time_expression_parser"]) {
$GLOBALS["_DbResult_time_expression_parser"] = new TimeExpressionParser();
}
if (!$GLOBALS["_DbResult_timecodeparser"]) {
$GLOBALS["_DbResult_timecodeparser"] = new TimecodeParser();
}
if (!$GLOBALS["_DbResult_mediainfocoder"]) {
$GLOBALS["_DbResult_mediainfocoder"] = MediaInfoCoder::load();
}
if (!$GLOBALS["_DbResult_fileinfocoder"]) {
$GLOBALS["_DbResult_fileinfocoder"] = FileInfoCoder::load();
}
// valid options and defaults
$this->opa_options = array('prefetch' => 50, 'prefetchAttributes' => null);
$this->opo_tep = $GLOBALS["_DbResult_time_expression_parser"];
if (!is_array(self::$s_template_prefetch_cache)) {
self::$s_template_prefetch_cache = array();
}
}