mirror of
https://github.com/pierre42100/ComunicAPI
synced 2025-06-19 16:45:17 +00:00
Returns group visibility
This commit is contained in:
@ -10,11 +10,17 @@ class GroupInfo extends BaseUniqueObject {
|
||||
//Path to group logo in user data
|
||||
const PATH_GROUPS_LOGO = "groups_logo";
|
||||
|
||||
//Groups visibility
|
||||
const OPEN_GROUP = 0;
|
||||
const PRIVATE_GROUP = 1;
|
||||
const SECRET_GROUP = 2;
|
||||
|
||||
//Private fields
|
||||
private $name;
|
||||
private $number_members = -1;
|
||||
private $logo;
|
||||
private $membership_level = -1;
|
||||
private $visiblity;
|
||||
|
||||
|
||||
//Get and set the name of group
|
||||
@ -83,4 +89,17 @@ class GroupInfo extends BaseUniqueObject {
|
||||
public function get_membership_level() : int {
|
||||
return $this->membership_level;
|
||||
}
|
||||
|
||||
//Get and set group visibility
|
||||
public function set_visibility(int $visibility){
|
||||
$this->visibility = $visibility;
|
||||
}
|
||||
|
||||
public function has_visibility() : bool {
|
||||
return $this->visibility > -1;
|
||||
}
|
||||
|
||||
public function get_visibility() : int {
|
||||
return $this->visibility;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user