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


PHP Api::__construct方法代码示例

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


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

示例1: __construct

 public function __construct()
 {
     parent::__construct();
     $this->paper_id = intval($this->data['paper_id']);
     $this->type = t($this->data['type']);
     $this->sysdao = M('sys_ana_test');
 }
开发者ID:317703064,项目名称:ssat,代码行数:7,代码来源:SsatPublicTestApi.class.php

示例2: __construct

 public function __construct()
 {
     parent::__construct();
     $this->paper_id = intval($this->data['paper_id']);
     $this->num = intval($this->data['num']);
     $this->articledao = M('ssat_article');
 }
开发者ID:317703064,项目名称:ssat,代码行数:7,代码来源:SsatArticleApi.class.php

示例3: __construct

 public function __construct()
 {
     parent::__construct();
     // 获取关键字
     $this->keyword = t($this->data['keyword']);
     $this->type = $this->data['type'] ? intval($this->data['type']) : 1;
     // 分页数
     $page = intval($this->data['page']);
     $page <= 0 && ($page = 1);
     // 分页大小
     $pageSize = 10;
     // 使用sphinx进行搜索功能
     $sphinx = new SphinxClient();
     // 配置sphinx服务器信息
     $sphinx->SetServer(self::SPHINX_HOST, self::SPHINX_PORT);
     // 配置返回结果集
     $sphinx->SetArrayResult(true);
     // 匹配结果偏移量
     $sphinx->SetLimits(($page - 1) * $pageSize, $pageSize, 1000);
     // 设置最大搜索时间
     $sphinx->SetMaxQueryTime(3);
     // 设置搜索模式
     $sphinx->setMatchMode(SPH_MATCH_PHRASE);
     $this->sphinx = $sphinx;
 }
开发者ID:317703064,项目名称:ssat,代码行数:25,代码来源:SearchApi.class.php

示例4:

 /**
  * Constructor
  */
 function __construct()
 {
     parent::__construct();
     $this->EE->load->model('template_model');
     // initialize the reserved names array
     $this->_load_reserved_groups();
 }
开发者ID:thomasvandoren,项目名称:teentix-site,代码行数:10,代码来源:Api_template_structure.php

示例5: __construct

 public function __construct()
 {
     parent::__construct();
     $this->paper_id = intval($this->data['paper_id']);
     $this->paper_section = intval($this->data['paper_section']);
     $this->article_id = intval($this->data['article_id']);
 }
开发者ID:317703064,项目名称:ssat,代码行数:7,代码来源:ArticleApi.class.php

示例6: __construct

 /**
  * Object constructor.
  */
 public function __construct($host, $shop_id, $shop_pass, $site_id, $site_pass, $params = array())
 {
     $params['shop_id'] = $shop_id;
     $params['shop_pass'] = $shop_pass;
     $params['site_id'] = $site_id;
     $params['site_pass'] = $site_pass;
     parent::__construct($host, $params);
 }
开发者ID:everright,项目名称:gmo-pg-php,代码行数:11,代码来源:ShopAndSiteApi.php

示例7: __construct

 /**
  * Site api constructor.
  */
 public function __construct($host, $site_id, $site_pass, $params = array())
 {
     if (!is_array($params)) {
         $params = array();
     }
     $params['site_id'] = $site_id;
     $params['site_pass'] = $site_pass;
     parent::__construct($host, $params);
 }
开发者ID:k1low,项目名称:gmo-pg-php,代码行数:12,代码来源:SiteApi.php

示例8: __construct

 public function __construct()
 {
     parent::__construct();
     $api = t($_REQUEST['api']);
     !$api['api'] && ($api = $this->api_list[0]);
     if (!in_array($api, $this->api_list)) {
         $return = array('code' => '00502', 'message' => '非法请求了哦');
         exit(json_encode($return));
     }
 }
开发者ID:medz,项目名称:thinksns-4,代码行数:10,代码来源:LiveOauthApi.class.php

示例9: __construct

 /**
  * Constructor.
  *
  * @param CentralAuthenticationStore $cas     Shared instance of the CentralAuthenticationStore class.
  * @param LoggerInterface            $logger  Shared instance of a Logger class.
  * @param Curl                       $curl    Shared instance of the Curl class.
  * @param RequestInterface           $request Shared instance of a Request class.
  */
 public function __construct($cas, $logger, $curl, $request)
 {
     parent::__construct($cas, $logger, $curl);
     $this->state = $request->get_get_data('state');
     $this->code = $request->get_get_data('code');
     $this->redirect_uri = $request->base_url . $request->call;
     $this->scope = NULL;
     $this->token_expires = 0;
     if ($this->state === NULL) {
         $this->state = md5(uniqid(rand(), TRUE));
     }
 }
开发者ID:rubendgr,项目名称:lunr,代码行数:20,代码来源:Authentication.php

示例10: __construct

 public function __construct($client, array $options = array())
 {
     parent::__construct($client);
     $this->reset();
     $this->set($options);
 }
开发者ID:dmyers,项目名称:octogun,代码行数:6,代码来源:Configuration.php

示例11: __construct

 public function __construct($key = null)
 {
     parent::__construct();
 }
开发者ID:iorichina,项目名称:geo,代码行数:4,代码来源:app.ApiRegion.php

示例12: ImagenesController

 function __construct($request)
 {
     parent::__construct($request);
     $this->controller = new ImagenesController();
 }
开发者ID:perezale,项目名称:mvc-example,代码行数:5,代码来源:imagen.php

示例13: ee

 /**
  * Constructor
  *
  */
 function __construct()
 {
     parent::__construct();
     ee()->load->model('channel_entries_model');
 }
开发者ID:nigelpeters,项目名称:css-recruitment-ee,代码行数:9,代码来源:Api_channel_entries.php

示例14: __construct

 /**
  * Constructor 
  *
  */
 public function __construct($configFile = null)
 {
     // Get the function-name for the jsonp callback
     $this->jsonPcallback = self::getJsonpCallback();
     // Set debug mode = true
     parent::__construct($configFile, true);
 }
开发者ID:wdiesveld,项目名称:tiny-queries-php-api,代码行数:11,代码来源:TinyQueries.php

示例15: Facebook

 function __construct()
 {
     parent::__construct();
     require 'facebook/facebook.php';
     $this->facebook = new Facebook(array('appId' => '368457244245', 'secret' => '1cbfe5aefa98de84245e0aebbbcb75cb'));
 }
开发者ID:HipsterJazzbo,项目名称:Syncosaurus,代码行数:6,代码来源:Facebook.php


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