<?php
/**
 * UserAccountManagementGranularInformation
 *
 * PHP version 5
 *
 * @category Class
 * @package  DocuSign\eSign
 * @author   Swaagger Codegen team
 * @link     https://github.com/swagger-api/swagger-codegen
 */

/**
 * DocuSign REST API
 *
 * The DocuSign REST API provides you with a powerful, convenient, and simple Web services API for interacting with DocuSign.
 *
 * OpenAPI spec version: v2
 * Contact: devcenter@docusign.com
 * Generated by: https://github.com/swagger-api/swagger-codegen.git
 *
 */

/**
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen
 * Do not edit the class manually.
 */

namespace DocuSign\eSign\Model;

use \ArrayAccess;

/**
 * UserAccountManagementGranularInformation Class Doc Comment
 *
 * @category    Class
 * @package     DocuSign\eSign
 * @author      Swagger Codegen team
 * @link        https://github.com/swagger-api/swagger-codegen
 */
class UserAccountManagementGranularInformation implements ArrayAccess
{
    const DISCRIMINATOR = null;

    /**
      * The original name of the model.
      * @var string
      */
    protected static $swaggerModelName = 'userAccountManagementGranularInformation';

    /**
      * Array of property to type mappings. Used for (de)serialization
      * @var string[]
      */
    protected static $swaggerTypes = [
        'can_manage_admins' => 'string',
        'can_manage_admins_metadata' => '\DocuSign\eSign\Model\SettingsMetadata',
        'can_manage_groups' => 'string',
        'can_manage_groups_metadata' => '\DocuSign\eSign\Model\SettingsMetadata',
        'can_manage_sharing' => 'string',
        'can_manage_sharing_metadata' => '\DocuSign\eSign\Model\SettingsMetadata',
        'can_manage_users' => 'string',
        'can_manage_users_metadata' => '\DocuSign\eSign\Model\SettingsMetadata'
    ];

    public static function swaggerTypes()
    {
        return self::$swaggerTypes;
    }

    /**
     * Array of attributes where the key is the local name, and the value is the original name
     * @var string[]
     */
    protected static $attributeMap = [
        'can_manage_admins' => 'canManageAdmins',
        'can_manage_admins_metadata' => 'canManageAdminsMetadata',
        'can_manage_groups' => 'canManageGroups',
        'can_manage_groups_metadata' => 'canManageGroupsMetadata',
        'can_manage_sharing' => 'canManageSharing',
        'can_manage_sharing_metadata' => 'canManageSharingMetadata',
        'can_manage_users' => 'canManageUsers',
        'can_manage_users_metadata' => 'canManageUsersMetadata'
    ];


    /**
     * Array of attributes to setter functions (for deserialization of responses)
     * @var string[]
     */
    protected static $setters = [
        'can_manage_admins' => 'setCanManageAdmins',
        'can_manage_admins_metadata' => 'setCanManageAdminsMetadata',
        'can_manage_groups' => 'setCanManageGroups',
        'can_manage_groups_metadata' => 'setCanManageGroupsMetadata',
        'can_manage_sharing' => 'setCanManageSharing',
        'can_manage_sharing_metadata' => 'setCanManageSharingMetadata',
        'can_manage_users' => 'setCanManageUsers',
        'can_manage_users_metadata' => 'setCanManageUsersMetadata'
    ];


    /**
     * Array of attributes to getter functions (for serialization of requests)
     * @var string[]
     */
    protected static $getters = [
        'can_manage_admins' => 'getCanManageAdmins',
        'can_manage_admins_metadata' => 'getCanManageAdminsMetadata',
        'can_manage_groups' => 'getCanManageGroups',
        'can_manage_groups_metadata' => 'getCanManageGroupsMetadata',
        'can_manage_sharing' => 'getCanManageSharing',
        'can_manage_sharing_metadata' => 'getCanManageSharingMetadata',
        'can_manage_users' => 'getCanManageUsers',
        'can_manage_users_metadata' => 'getCanManageUsersMetadata'
    ];

    public static function attributeMap()
    {
        return self::$attributeMap;
    }

    public static function setters()
    {
        return self::$setters;
    }

    public static function getters()
    {
        return self::$getters;
    }

    

    

    /**
     * Associative array for storing property values
     * @var mixed[]
     */
    protected $container = [];

    /**
     * Constructor
     * @param mixed[] $data Associated array of property values initializing the model
     */
    public function __construct(array $data = null)
    {
        $this->container['can_manage_admins'] = isset($data['can_manage_admins']) ? $data['can_manage_admins'] : null;
        $this->container['can_manage_admins_metadata'] = isset($data['can_manage_admins_metadata']) ? $data['can_manage_admins_metadata'] : null;
        $this->container['can_manage_groups'] = isset($data['can_manage_groups']) ? $data['can_manage_groups'] : null;
        $this->container['can_manage_groups_metadata'] = isset($data['can_manage_groups_metadata']) ? $data['can_manage_groups_metadata'] : null;
        $this->container['can_manage_sharing'] = isset($data['can_manage_sharing']) ? $data['can_manage_sharing'] : null;
        $this->container['can_manage_sharing_metadata'] = isset($data['can_manage_sharing_metadata']) ? $data['can_manage_sharing_metadata'] : null;
        $this->container['can_manage_users'] = isset($data['can_manage_users']) ? $data['can_manage_users'] : null;
        $this->container['can_manage_users_metadata'] = isset($data['can_manage_users_metadata']) ? $data['can_manage_users_metadata'] : null;
    }

    /**
     * show all the invalid properties with reasons.
     *
     * @return array invalid properties with reasons
     */
    public function listInvalidProperties()
    {
        $invalid_properties = [];
        return $invalid_properties;
    }

    /**
     * validate all the properties in the model
     * return true if all passed
     *
     * @return bool True if all properteis are valid
     */
    public function valid()
    {
        return true;
    }


    /**
     * Gets can_manage_admins
     * @return string
     */
    public function getCanManageAdmins()
    {
        return $this->container['can_manage_admins'];
    }

    /**
     * Sets can_manage_admins
     * @param string $can_manage_admins 
     * @return $this
     */
    public function setCanManageAdmins($can_manage_admins)
    {
        $this->container['can_manage_admins'] = $can_manage_admins;

        return $this;
    }

    /**
     * Gets can_manage_admins_metadata
     * @return \DocuSign\eSign\Model\SettingsMetadata
     */
    public function getCanManageAdminsMetadata()
    {
        return $this->container['can_manage_admins_metadata'];
    }

    /**
     * Sets can_manage_admins_metadata
     * @param \DocuSign\eSign\Model\SettingsMetadata $can_manage_admins_metadata
     * @return $this
     */
    public function setCanManageAdminsMetadata($can_manage_admins_metadata)
    {
        $this->container['can_manage_admins_metadata'] = $can_manage_admins_metadata;

        return $this;
    }

    /**
     * Gets can_manage_groups
     * @return string
     */
    public function getCanManageGroups()
    {
        return $this->container['can_manage_groups'];
    }

    /**
     * Sets can_manage_groups
     * @param string $can_manage_groups 
     * @return $this
     */
    public function setCanManageGroups($can_manage_groups)
    {
        $this->container['can_manage_groups'] = $can_manage_groups;

        return $this;
    }

    /**
     * Gets can_manage_groups_metadata
     * @return \DocuSign\eSign\Model\SettingsMetadata
     */
    public function getCanManageGroupsMetadata()
    {
        return $this->container['can_manage_groups_metadata'];
    }

    /**
     * Sets can_manage_groups_metadata
     * @param \DocuSign\eSign\Model\SettingsMetadata $can_manage_groups_metadata
     * @return $this
     */
    public function setCanManageGroupsMetadata($can_manage_groups_metadata)
    {
        $this->container['can_manage_groups_metadata'] = $can_manage_groups_metadata;

        return $this;
    }

    /**
     * Gets can_manage_sharing
     * @return string
     */
    public function getCanManageSharing()
    {
        return $this->container['can_manage_sharing'];
    }

    /**
     * Sets can_manage_sharing
     * @param string $can_manage_sharing 
     * @return $this
     */
    public function setCanManageSharing($can_manage_sharing)
    {
        $this->container['can_manage_sharing'] = $can_manage_sharing;

        return $this;
    }

    /**
     * Gets can_manage_sharing_metadata
     * @return \DocuSign\eSign\Model\SettingsMetadata
     */
    public function getCanManageSharingMetadata()
    {
        return $this->container['can_manage_sharing_metadata'];
    }

    /**
     * Sets can_manage_sharing_metadata
     * @param \DocuSign\eSign\Model\SettingsMetadata $can_manage_sharing_metadata
     * @return $this
     */
    public function setCanManageSharingMetadata($can_manage_sharing_metadata)
    {
        $this->container['can_manage_sharing_metadata'] = $can_manage_sharing_metadata;

        return $this;
    }

    /**
     * Gets can_manage_users
     * @return string
     */
    public function getCanManageUsers()
    {
        return $this->container['can_manage_users'];
    }

    /**
     * Sets can_manage_users
     * @param string $can_manage_users 
     * @return $this
     */
    public function setCanManageUsers($can_manage_users)
    {
        $this->container['can_manage_users'] = $can_manage_users;

        return $this;
    }

    /**
     * Gets can_manage_users_metadata
     * @return \DocuSign\eSign\Model\SettingsMetadata
     */
    public function getCanManageUsersMetadata()
    {
        return $this->container['can_manage_users_metadata'];
    }

    /**
     * Sets can_manage_users_metadata
     * @param \DocuSign\eSign\Model\SettingsMetadata $can_manage_users_metadata
     * @return $this
     */
    public function setCanManageUsersMetadata($can_manage_users_metadata)
    {
        $this->container['can_manage_users_metadata'] = $can_manage_users_metadata;

        return $this;
    }
    /**
     * Returns true if offset exists. False otherwise.
     * @param  integer $offset Offset
     * @return boolean
     */
    public function offsetExists($offset)
    {
        return isset($this->container[$offset]);
    }

    /**
     * Gets offset.
     * @param  integer $offset Offset
     * @return mixed
     */
    public function offsetGet($offset)
    {
        return isset($this->container[$offset]) ? $this->container[$offset] : null;
    }

    /**
     * Sets value based on offset.
     * @param  integer $offset Offset
     * @param  mixed   $value  Value to be set
     * @return void
     */
    public function offsetSet($offset, $value)
    {
        if (is_null($offset)) {
            $this->container[] = $value;
        } else {
            $this->container[$offset] = $value;
        }
    }

    /**
     * Unsets offset.
     * @param  integer $offset Offset
     * @return void
     */
    public function offsetUnset($offset)
    {
        unset($this->container[$offset]);
    }

    /**
     * Gets the string presentation of the object
     * @return string
     */
    public function __toString()
    {
        if (defined('JSON_PRETTY_PRINT')) { // use JSON pretty print
            return json_encode(\DocuSign\eSign\ObjectSerializer::sanitizeForSerialization($this), JSON_PRETTY_PRINT);
        }

        return json_encode(\DocuSign\eSign\ObjectSerializer::sanitizeForSerialization($this));
    }
}


