本文整理汇总了PHP中Owner::fromJson方法的典型用法代码示例。如果您正苦于以下问题:PHP Owner::fromJson方法的具体用法?PHP Owner::fromJson怎么用?PHP Owner::fromJson使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Owner
的用法示例。
在下文中一共展示了Owner::fromJson方法的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: fromJson
public static function fromJson($json)
{
// Currently, we only support json object
if (is_object($json)) {
$acp = new AccessControlPolicy();
if (isset($json->owner)) {
$acp->setOwner(Owner::fromJson($json->owner));
}
if (isset($json->accessControlList)) {
$acp->setAccessControlList($json->accessControlList);
}
return $acp;
}
return NULL;
}
示例2: fromJson
public static function fromJson($json)
{
// Currently, we only support json object
if (is_object($json)) {
$bucket = new FDSBucket();
if (isset($json->name)) {
$bucket->setName($json->name);
}
if (isset($json->creation_date)) {
$bucket->setCreationDate($json->creation_date);
}
if (isset($json->owner)) {
$bucket->setOwner(Owner::fromJson($json->owner));
}
return $bucket;
}
return NULL;
}
示例3: fromJson
public static function fromJson($json)
{
// Currently, we only support json object
if (is_object($json)) {
$summary = new FDSObjectSummary();
if (isset($json->name)) {
$summary->setObjectName($json->name);
}
if (isset($json->owner)) {
$summary->setOwner(Owner::fromJson($json->owner));
}
if (isset($json->size)) {
$summary->setSize($json->size);
}
return $summary;
}
return NULL;
}