本文整理汇总了PHP中Query::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Query::__construct方法的具体用法?PHP Query::__construct怎么用?PHP Query::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Query
的用法示例。
在下文中一共展示了Query::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
/**
* Optionally sets the table name and initializes the internal class
* properties.
*
* @param string $table The name of the table
*/
public function __construct($table = null)
{
$this->where = new \Bistro\Data\Query\Where();
$this->order_by = new \Bistro\Data\Query\Order();
$this->limit = new \Bistro\Data\Query\Limit();
parent::__construct($table);
}
示例2: __construct
/**
* 析构函数
*/
public function __construct(Connection $connection, $options)
{
parent::__construct($connection, $options);
if (!empty($options['database'])) {
$this->explainSchema($options);
}
}
示例3: __construct
public function __construct(Connection $connection, $table, array $options = array())
{
$options['return'] = Database::RETURN_AFFECTED;
parent::__construct($connection, $options);
$this->table = $table;
$this->condition = new Condition('AND');
}
示例4:
function __construct($conn, $game, $player)
{
//set our connection
parent::__construct($conn);
$this->player = $player;
$this->sql = "SELECT player1, player2 FROM game WHERE game_id='{$game}';";
}
示例5: __construct
public function __construct(Entity $searchEntity, QueryContext $queryContext, Scope $defaultScope, $id = NULL, $skipBinaries = FALSE)
{
parent::__construct($queryContext);
$this->searchEntity = $searchEntity;
$this->queryParams = $queryContext->getQueryParameters($searchEntity, $id);
$this->propertyNames = array();
$this->scope = $queryContext->getScope($searchEntity, $defaultScope);
$this->skipBinaries = $skipBinaries;
// If the scope doesn't include property values...
if ($this->scope->includes(Scope::TAG_PROPERTIES) == Scope::INCLUDES_NONE) {
// ...then only fetch the object id and any foreign keys.
if ($this->searchEntity->isObjectEntity()) {
$this->propertyNames[] = $this->searchEntity->getObjectIdColumnName();
}
foreach ($this->searchEntity->getRelationships() as $relationship) {
if ($relationship->getFkEntity() != $this->searchEntity) {
continue;
}
$toEntity = $relationship->getOppositeEntity($this->searchEntity);
$this->propertyNames[] = $relationship->getFkColumnName($toEntity);
}
}
// Create the first two aliases for the table and its state.
$this->createAlias();
$this->createAlias();
// Add the query parameters to the where-clause.
foreach ($this->queryParams as $paramName => $paramValue) {
$property = $this->searchEntity->getProperty($paramName, FALSE);
if ($property == NULL) {
// error_log("Ignoring unknown query parameter: '$paramName=$paramValue'.");
} else {
$this->addWhereClause($paramName, $paramValue);
}
}
}
示例6: __construct
public function __construct($map, $queryType, $poly)
{
$_REQUEST['mode'] = 'nquery';
parent::__construct($map);
$this->queryType = $queryType ? $queryType : 'simple';
$this->poly = $poly;
}
示例7: __construct
/**
* Create a new instance.
*
* @param string $domain (optional) The Google Apps-hosted domain to use
* when constructing query URIs.
* @param string $emailListName (optional) Value for the emailListName
* property.
* @param string $recipient (optional) Value for the recipient
* property.
* @param string $startEmailListName (optional) Value for the
* startEmailListName property.
*/
public function __construct($domain = null, $emailListName = null, $recipient = null, $startEmailListName = null)
{
parent::__construct($domain);
$this->setEmailListName($emailListName);
$this->setRecipient($recipient);
$this->setStartEmailListName($startEmailListName);
}
示例8: __construct
/**
* Create a new instance.
*
* @param string $domain (optional) The Google Apps-hosted domain to use
* when constructing query URIs.
* @param string $nickname (optional) Value for the nickname
* property.
* @param string $username (optional) Value for the username
* property.
* @param string $startNickname (optional) Value for the
* startNickname property.
*/
public function __construct($domain = null, $nickname = null, $username = null, $startNickname = null)
{
parent::__construct($domain);
$this->setNickname($nickname);
$this->setUsername($username);
$this->setStartNickname($startNickname);
}
示例9:
function __construct($conn, $game)
{
//set our connection
parent::__construct($conn);
$this->game = $game;
$this->sql = "SELECT * FROM game WHERE game_id='{$game}';";
}
示例10: __construct
public function __construct()
{
parent::__construct();
$this->addModules([new MomentJs(), new Form(), new Button()]);
$this->addFiles(["modules/Table/Table.min.js", "modules/Table/classes/Form.min.js", "modules/Table/Table.min.css"]);
$this->init();
}
示例11: __construct
public function __construct(Type &$_typeObject)
{
$this->_typeObject = $_typeObject;
$this->postType = $_typeObject->getPostType();
$args = $_typeObject->getQueryArgs();
parent::__construct($args, $this->postType);
}
示例12: Localize
function __construct()
{
// jalg multi 5-7-2015
parent::__construct();
// function CircQuery() {
// $this->Query();
$this->_loc = new Localize(OBIB_LOCALE, 'classes');
}
示例13: __construct
public function __construct($_form = "")
{
parent::__construct();
$this->form = $_form;
$this->addfile("modules/Form/Form.min.css");
$this->message = "I campi contrassegnati con * sono obbligatori.<br>";
$this->tablesCached = [];
}
示例14: Localize
function __construct()
{
//jalg multi 5-7-2015
parent::__construct();
// function MemberAccountQuery() {
$this->Query();
$this->_loc = new Localize(OBIB_LOCALE, "classes");
}
示例15: __construct
/**
* Constructor.
*
* @param int|null $id
* @param boolean $cached
*/
public function __construct($id = null, $cached = true)
{
parent::__construct($id, $cached);
if (!$id) {
$this->set_use_pages(true);
$this->set_use_alpha(false);
}
$this->show_header = true;
}