本文整理汇总了PHP中Object::construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Object::construct方法的具体用法?PHP Object::construct怎么用?PHP Object::construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Object
的用法示例。
在下文中一共展示了Object::construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: __construct
function __construct()
{
$this->counter1 = Object::construct("WHCounter");
$this->counter2 = Object::construct("WHCounter");
$this->counter3 = Object::construct("WHCounter");
$this->counter4 = Object::construct("WHCounter");
}
示例2: fromSqlValueStringWithConnection
public function fromSqlValueStringWithConnection($aString, $reServeConnection)
{
if ($aString == NULL) {
return NULL;
}
return Object::construct("REServeProxyObject")->setDatabase($reServeConnection)->setOid((int) $aString);
}
示例3: __construct
public function __construct()
{
foreach ($this->classes as $class) {
$objects[] = Object::construct($class);
}
return $this;
}
示例4: onAnswerCallback
public function onAnswerCallback($object, $method, $arguments = "")
{
if ($arguments == "") {
$arguments = array();
}
$this->dialogCallback = Object::construct("WHCallback")->setObject($object)->setMethod($method)->setArguments($arguments);
return $this;
}
示例5: startUpOnAppWithIni
static function startUpOnAppWithIni($app, $app_configuration)
{
ini_set("session.use_cookies", $app_configuration['general']['use_cookie']);
ini_set("session.name", "SID");
$configuration_class = $app_configuration['general']['configuration_class'];
$configuration = Object::construct($configuration_class);
$configuration->setApplicationName($app)->setConfigValues($app_configuration);
return $configuration;
}
示例6: dayOfMeeting
public function dayOfMeeting()
{
/*
** Lazy initialization
*/
if ($this->dayOfMeeting == NULL) {
$this->dayOfMeeting = Object::construct("WHDate");
}
return $this->dayOfMeeting;
}
示例7: start
public function start()
{
parent::start();
if (!is_object($this->db)) {
$this->db = Object::construct($this->configuration()->configValueBySubjectAndKey("REServe", "type"));
$this->db->setAutomaticTableCreation($automatic_table_creation);
}
$this->connect();
return $this;
}
示例8: column
public function column($aKeyPath, $aClass, $aRowName = "", $shouldUpdateValue = TRUE)
{
if ($aRowName == "") {
$aRowName = $aKeyPath;
}
if (!is_object($aClass)) {
$aClass = Object::construct($aClass);
}
$this->columns[] = Object::construct('REServeColumnDefinition')->setName($aRowName)->setKeyPath($aKeyPath)->setType($aClass)->setShouldUpdateValue($shouldUpdateValue);
return $this;
}
示例9: tableDefinition
public function tableDefinition()
{
return Object::construct("REServeTableDefinition")->column("oid", "REServeCollectionId", 'objectId', FALSE)->column('parentId', REInteger)->column('key', REInteger)->column('value', $this->valueType());
}
示例10: registerObjectOnKeyPath
public function registerObjectOnKeyPath($anObject, $aStringKeyPath)
{
$this->registeredObjects[] = Object::construct("WHRegisteredObject")->setOnObject($anObject)->setKeyPath($aStringKeyPath)->setValue($anObject->getByKeyPath($aStringKeyPath));
return $this;
}
示例11: callbackForRemove
public function callbackForRemove($object, $method)
{
$this->removeCallback = Object::construct("WHCallback")->setObject($object)->setMethod($method);
}
示例12: setCurrentContact
public function setCurrentContact($aContact)
{
$this->currentContactComponent = Object::construct("WHREServeModelEdit")->setReserveable($aContact);
return $this;
}
示例13: fromSqlValueStringWithConnection
public function fromSqlValueStringWithConnection($aString, $reServeConnection)
{
if ($aString == NULL) {
return NULL;
}
$toReturn = Object::construct("REServeProxyObject")->setDatabase($reServeConnection)->setOid((int) $aString)->setObjectClass(get_class($this));
$reServeConnection->putInCache($toReturn);
return $toReturn;
}
示例14: registerCollectionCallback
public function registerCollectionCallback($object, $method, $arguments, $collection)
{
$newKey = $this->newCallbackKey();
$this->callbacks[$newKey] = Object::construct("WHCollectionCallback")->setKey($newKey)->setObject($object)->setMethod($method)->setArguments($arguments)->setItems($collection);
return $this->callbacks[$newKey];
}
示例15: objectForOidWithClass
public function objectForOidWithClass($anOid, $aClass)
{
if ($this->getFromCache($anOid) != NULL) {
return $this->getFromCache($anOid);
} else {
$result = $this->executeQuery($this->queryForLookupClassWithOid($aClass, $anOid));
$array = mysql_fetch_array($result);
foreach (Object::construct($aClass)->tableDefinition()->columns() as $column) {
$this->currentColumn($column);
if ($column->type()->reServeValueStoredWithObject()) {
$dRow[$column->keyPath()] = $array[$column->name()];
}
}
return $this->objectForOidWithClassFromArray($anOid, $aClass, $dRow);
}
}