<?php declare(strict_types=1); /* * Copyright (c) Ne-Lexa * * For the full copyright and license information, please view * the LICENSE file that was distributed with this source code. * * @see https://github.com/Ne-Lexa/google-play-scraper */ namespace Nelexa\GPlay\Model; /** * Contains information about application permissions. */ class Permission implements \JsonSerializable { use JsonSerializableTrait; /** @var string Permission label. */ private $label; /** @var GoogleImage */ private $icon; /** @var string[] Permissions. */ private $permissions; /** * Permission constructor. * * @param string $label * @param GoogleImage $icon * @param string[] $permissions */ public function __construct(string $label, GoogleImage $icon, array $permissions) { $this->label = $label; $this->icon = $icon; $this->permissions = $permissions; } /** * @return string */ public function getLabel(): string { return $this->label; } /** * @return GoogleImage */ public function getIcon(): GoogleImage { return $this->icon; } /** * @return string[] */ public function getPermissions(): array { return $this->permissions; } /** * Returns class properties as an array. * * @return array class properties as an array */ public function asArray(): array { return [ 'label' => $this->label, 'icon' => $this->icon->getUrl(), 'permissions' => $this->permissions, ]; } }
Name | Type | Size | Permission | Actions |
---|---|---|---|---|
Builder | Folder | 0755 |
|
|
App.php | File | 7.76 KB | 0644 |
|
AppId.php | File | 3.71 KB | 0644 |
|
AppInfo.php | File | 14.86 KB | 0644 |
|
Category.php | File | 2.64 KB | 0644 |
|
ClusterPage.php | File | 1.37 KB | 0644 |
|
Developer.php | File | 7.02 KB | 0644 |
|
GoogleImage.php | File | 24.22 KB | 0644 |
|
HistogramRating.php | File | 3.23 KB | 0644 |
|
ImageInfo.php | File | 3.26 KB | 0644 |
|
JsonSerializableTrait.php | File | 1.14 KB | 0644 |
|
Permission.php | File | 1.63 KB | 0644 |
|
ReplyReview.php | File | 1.83 KB | 0644 |
|
Review.php | File | 4.98 KB | 0644 |
|
Video.php | File | 2.32 KB | 0644 |
|