当前位置: 首页>>代码示例>>PHP>>正文


PHP ca_metadata_elements::getRootElementsAsList方法代码示例

本文整理汇总了PHP中ca_metadata_elements::getRootElementsAsList方法的典型用法代码示例。如果您正苦于以下问题:PHP ca_metadata_elements::getRootElementsAsList方法的具体用法?PHP ca_metadata_elements::getRootElementsAsList怎么用?PHP ca_metadata_elements::getRootElementsAsList使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ca_metadata_elements的用法示例。


在下文中一共展示了ca_metadata_elements::getRootElementsAsList方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: Index

 public function Index()
 {
     AssetLoadManager::register('tableList');
     $vo_dm = Datamodel::load();
     $va_elements = ca_metadata_elements::getRootElementsAsList(null, null, true, true);
     $this->view->setVar('element_list', $va_elements);
     $this->view->setVar('attribute_types', Attribute::getAttributeTypes());
     $o_result_context = new ResultContext($this->request, $this->ops_table_name, 'basic_search');
     $o_result_context->setResultList(array_keys($va_elements));
     $o_result_context->setAsLastFind();
     $o_result_context->saveContext();
     return $this->render('elements_list_html.php');
 }
开发者ID:samrahman,项目名称:providence,代码行数:13,代码来源:ElementsController.php

示例2: __construct

 public function __construct()
 {
     parent::__construct();
     $this->opo_tep = new TimeExpressionParser();
     $this->ops_lookup_word_sql = "\n\t\t\tSELECT word_id \n\t\t\tFROM ca_sql_search_words\n\t\t\tWHERE\n\t\t\t\tword = ?\n\t\t";
     $this->opqr_lookup_word = $this->opo_db->prepare($this->ops_lookup_word_sql);
     $this->ops_insert_word_index_sql = "\n\t\t\tINSERT  INTO ca_sql_search_word_index\n\t\t\t(table_num, row_id, field_table_num, field_num, field_row_id, word_id, boost, access)\n\t\t\tVALUES\n\t\t";
     $this->ops_insert_word_sql = "\n\t\t\tINSERT  INTO ca_sql_search_words\n\t\t\t(word, stem)\n\t\t\tVALUES\n\t\t\t(?, ?)\n\t\t";
     $this->ops_insert_ngram_sql = "\n\t\t\tINSERT  INTO ca_sql_search_ngrams\n\t\t\t(word_id, ngram, seq)\n\t\t\tVALUES\n\t\t";
     $this->opqr_insert_word = $this->opo_db->prepare($this->ops_insert_word_sql);
     $this->ops_delete_sql = "DELETE FROM ca_sql_search_word_index WHERE (table_num = ?) AND (row_id = ?)";
     $this->opqr_delete = $this->opo_db->prepare($this->ops_delete_sql);
     $this->ops_delete_with_field_num_sql = "DELETE FROM ca_sql_search_word_index WHERE (table_num = ?) AND (row_id = ?) AND (field_table_num = ?) AND (field_num = ?)";
     $this->opqr_delete_with_field_num = $this->opo_db->prepare($this->ops_delete_with_field_num_sql);
     $this->ops_delete_with_field_row_id_sql = "DELETE FROM ca_sql_search_word_index WHERE (table_num = ?) AND (row_id = ?) AND (field_table_num = ?) AND (field_row_id = ?)";
     $this->opqr_delete_with_field_row_id = $this->opo_db->prepare($this->ops_delete_with_field_row_id_sql);
     $this->ops_delete_with_field_row_id_and_num = "DELETE FROM ca_sql_search_word_index WHERE (table_num = ?) AND (row_id = ?) AND (field_table_num = ?) AND (field_num = ?) AND (field_row_id = ?)";
     $this->opqr_delete_with_field_row_id_and_num = $this->opo_db->prepare($this->ops_delete_with_field_row_id_and_num);
     $this->ops_delete_dependent_sql = "DELETE FROM ca_sql_search_word_index WHERE (field_table_num = ?) AND (field_row_id = ?)";
     $this->opqr_delete_dependent_sql = $this->opo_db->prepare($this->ops_delete_dependent_sql);
     $this->opo_stemmer = new SnoballStemmer();
     $this->opb_do_stemming = (int) trim($this->opo_search_config->get('search_sql_search_do_stemming')) ? true : false;
     if (!($this->ops_indexing_tokenizer_regex = trim($this->opo_search_config->get('indexing_tokenizer_regex')))) {
         $this->ops_indexing_tokenizer_regex = "^\\pL\\pN\\pNd/_#\\@\\&\\.";
     }
     if (!($this->ops_search_tokenizer_regex = trim($this->opo_search_config->get('search_tokenizer_regex')))) {
         $this->ops_search_tokenizer_regex = "^\\pL\\pN\\pNd/_#\\@\\&";
     }
     if (!is_array($this->opa_asis_regexes = $this->opo_search_config->getList('asis_regexes'))) {
         $this->opa_asis_regexes = array();
     }
     //$this->opqr_insert_ngram = $this->opo_db->prepare($this->ops_insert_ngram_sql);
     //
     // Load info about metadata elements into static var cache if it hasn't already be fetched
     //
     if (!is_array(WLPlugSearchEngineSqlSearch::$s_metadata_elements)) {
         WLPlugSearchEngineSqlSearch::$s_metadata_elements = ca_metadata_elements::getRootElementsAsList();
     }
     $this->debug = false;
 }
开发者ID:guaykuru,项目名称:pawtucket,代码行数:40,代码来源:SqlSearch.php

示例3: __construct

 public function __construct($po_db = null)
 {
     parent::__construct($po_db);
     $this->opo_tep = new TimeExpressionParser();
     $this->opo_stemmer = new SnoballStemmer();
     $this->opb_do_stemming = (int) trim($this->opo_search_config->get('search_sql_search_do_stemming')) ? true : false;
     $this->initDbStatements();
     if (!($this->ops_indexing_tokenizer_regex = trim($this->opo_search_config->get('indexing_tokenizer_regex')))) {
         $this->ops_indexing_tokenizer_regex = "^\\pL\\pN\\pNd/_#\\@\\&\\.";
     }
     if (!($this->ops_search_tokenizer_regex = trim($this->opo_search_config->get('search_tokenizer_regex')))) {
         $this->ops_search_tokenizer_regex = "^\\pL\\pN\\pNd/_#\\@\\&";
     }
     if (!is_array($this->opa_asis_regexes = $this->opo_search_config->getList('asis_regexes'))) {
         $this->opa_asis_regexes = array();
     }
     //
     // Load info about metadata elements into static var cache if it hasn't already be fetched
     //
     if (!is_array(WLPlugSearchEngineSqlSearch::$s_metadata_elements)) {
         WLPlugSearchEngineSqlSearch::$s_metadata_elements = ca_metadata_elements::getRootElementsAsList();
     }
     $this->debug = false;
 }
开发者ID:ymani2435,项目名称:providence,代码行数:24,代码来源:SqlSearch.php


注:本文中的ca_metadata_elements::getRootElementsAsList方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。