本文整理汇总了PHP中Resource::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Resource::__construct方法的具体用法?PHP Resource::__construct怎么用?PHP Resource::__construct使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Resource
的用法示例。
在下文中一共展示了Resource::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
/**
* Create a new LinkCategory
* @param int $id
* @param string $title
* @param string $description
*/
function __construct($id, $title, $description, $display_order)
{
parent::__construct($id, RESOURCE_LINKCATEGORY);
$this->title = $title;
$this->description = $description;
$this->display_order = $display_order;
}
示例2: __construct
public function __construct()
{
parent::__construct();
$this->title = new \phpws2\Variable\TextOnly(null, 'title');
$this->title->allowEmpty(false);
$this->active = new \phpws2\Variable\Bool(true, 'active');
}
示例3: __construct
public function __construct()
{
parent::__construct();
$this->display_name = new \Variable\TextOnly(null, 'display_name');
$this->description = new \Variable\TextOnly(null, 'description');
$this->active = new \Variable\Integer(1, 'active');
}
示例4: __construct
public function __construct()
{
parent::__construct('token');
$this->reg_method('GET', 'GET_token');
$this->reg_json_method('POST', 'POST_token', ['password' => 's']);
$this->reg_json_method('DELETE', 'DELETE_token', ['token' => 's']);
}
示例5: __construct
public function __construct()
{
parent::__construct();
$this->device_id = new \Variable\Integer(0, 'device_id');
$this->primary_monitor = new \Variable\TextOnly(null, 'primary_monitor');
$this->primary_monitor->allowNull(true);
$this->secondary_monitor = new \Variable\TextOnly(null, 'secondary_monitor');
$this->secondary_monitor->allowNull(true);
$this->video_card = new \Variable\TextOnly(null, 'video_card');
$this->video_card->allowNull(true);
$this->os = new \Variable\TextOnly(null, 'os');
$this->os->allowNull(true);
$this->server_type = new \Variable\TextOnly(null, 'server_type');
$this->server_type->allowNull(true);
$this->system_usage = new \Variable\Integer(0, 'system_usage');
$this->system_usage->allowNull(true);
$this->battery_backup = new \Variable\Bool(false, 'battery_backup');
$this->redundant_backup = new \Variable\Bool(false, 'redundant_backup');
$this->rotation = new \Variable\Bool(false, 'rotation');
$this->stand = new \Variable\Bool(false, 'stand');
$this->touch_screen = new \Variable\Bool(false, 'touch_screen');
$this->dual_monitor = new \Variable\Bool(false, 'dual_monitor');
$this->check_in = new \Variable\Bool(false, 'check_in');
$this->smart_room = new \Variable\Bool(false, 'smart_room');
}
示例6: __construct
/**
* Create a new course description
* @param int $id
* @param string $title
* @param string $content
*/
public function __construct($id, $title, $content, $description_type)
{
parent::__construct($id, RESOURCE_COURSEDESCRIPTION);
$this->title = $title;
$this->content = $content;
$this->description_type = $description_type;
}
示例7: __construct
/**
* Create a new Glossary
* @param int $id
* @param string $name
* @param string $description
* @param int $display_order
*/
public function __construct($id, $name, $description, $display_order)
{
parent::__construct($id, RESOURCE_GLOSSARY);
$this->glossary_id = $id;
$this->name = $name;
$this->description = $description;
$this->display_order = $display_order;
}
示例8: __construct
public function __construct($clientId, $body = false)
{
if ($body && $body->data) {
$this->data = $body->data;
unset($body->data);
}
parent::__construct($clientId, $body);
}
示例9: __construct
/**
* Create a new SurveyInvitation
* @param int $id
* @param string $code
* @param string $user
* @param string $invitation_code
* @param string $invitation_date
* @param string $reminder_date
*/
public function __construct($id, $code, $user, $invitation_code, $invitation_date, $reminder_date)
{
parent::__construct($id, RESOURCE_SURVEYINVITATION);
$this->code = $code;
$this->user = $user;
$this->invitation_code = $invitation_code;
$this->invitation_date = $invitation_date;
$this->reminder_date = $reminder_date;
}
示例10: __construct
/**
* Create a new Link
* @param int $id The id of this link in the Chamilo-course
* @param string $title
* @param string $url
* @param string $description
*/
public function __construct($id, $title, $url, $description, $category_id, $on_homepage)
{
parent::__construct($id, RESOURCE_LINK);
$this->title = $title;
$this->url = $url;
$this->description = $description;
$this->category_id = $category_id;
$this->on_homepage = $on_homepage;
}
示例11: __construct
public function __construct()
{
parent::__construct();
$this->device_id = new \Variable\Integer(0, 'device_id');
$this->generation = new \Variable\TextOnly(null, 'generation');
$this->generation->allowNull(true);
$this->apple_id = new \Variable\TextOnly(null, 'apple_id');
$this->apple_id->allowNull(true);
}
示例12: array
function __construct()
{
parent::__construct();
$this->restype = 'computer';
$this->restypename = 'Computer';
$this->namefield = 'hostname';
$this->defaultGetDataArgs = array('sort' => 0, 'includedeleted' => 0, 'rscid' => '');
$this->basecdata['obj'] = $this;
}
示例13: __construct
/**
* Create a new Document
* @param int $id
* @param string $path
* @param string $comment
* @param string $title
* @param string $file_type (DOCUMENT or FOLDER);
* @param int $size
*/
public function __construct($id, $path, $comment, $title, $file_type, $size)
{
parent::__construct($id, RESOURCE_DOCUMENT);
$this->path = 'document' . $path;
$this->comment = $comment;
$this->title = $title;
$this->file_type = $file_type;
$this->size = $size;
}
示例14: __construct
public function __construct()
{
parent::__construct();
$this->lot_id = new \phpws2\Variable\Integer(null, 'lot_id');
$this->number = new \phpws2\Variable\Integer(null, 'number');
$this->reserved = new \phpws2\Variable\Bool(false, 'reserved');
$this->sober = new \phpws2\Variable\Bool(false, 'sober');
$this->active = new \phpws2\Variable\Bool(true, 'active');
}
示例15: array
function __construct()
{
parent::__construct();
$this->restype = 'config';
$this->restypename = 'Config';
$this->namefield = 'name';
$this->defaultGetDataArgs = array('rscid' => 0, 'includedeleted' => 0);
$this->basecdata['obj'] = $this;
}