# -*- coding: utf-8 -*-

"""
restapisdk

This file was automatically generated by APIMATIC v3.0 (
 https://www.apimatic.io ).
"""


class AdminsyncPrincipalResponse(object):

    """Implementation of the 'AdminsyncPrincipalResponse' model.

    TODO: type model description here.

    Attributes:
        users_added (list of string): Username of list of users added
        users_deleted (list of string): Username of list of users deleted
        users_updated (list of string): Username of list of users updated
        groups_added (list of string): Group name of list of groups added
        groups_deleted (list of string): Group name of list of groups deleted
        groups_updated (list of string): Group name of list of groups updated

    """

    # Create a mapping from Model property names to API property names
    _names = {
        "users_added": 'usersAdded',
        "users_deleted": 'usersDeleted',
        "users_updated": 'usersUpdated',
        "groups_added": 'groupsAdded',
        "groups_deleted": 'groupsDeleted',
        "groups_updated": 'groupsUpdated'
    }

    def __init__(self,
                 users_added=None,
                 users_deleted=None,
                 users_updated=None,
                 groups_added=None,
                 groups_deleted=None,
                 groups_updated=None):
        """Constructor for the AdminsyncPrincipalResponse class"""

        # Initialize members of the class
        self.users_added = users_added
        self.users_deleted = users_deleted
        self.users_updated = users_updated
        self.groups_added = groups_added
        self.groups_deleted = groups_deleted
        self.groups_updated = groups_updated

    @classmethod
    def from_dictionary(cls,
                        dictionary):
        """Creates an instance of this model from a dictionary

        Args:
            dictionary (dictionary): A dictionary representation of the object
            as obtained from the deserialization of the server's response. The
            keys MUST match property names in the API description.

        Returns:
            object: An instance of this structure class.

        """
        if dictionary is None:
            return None

        # Extract variables from the dictionary
        users_added = dictionary.get('usersAdded')
        users_deleted = dictionary.get('usersDeleted')
        users_updated = dictionary.get('usersUpdated')
        groups_added = dictionary.get('groupsAdded')
        groups_deleted = dictionary.get('groupsDeleted')
        groups_updated = dictionary.get('groupsUpdated')

        # Return an object of this model
        return cls(users_added,
                   users_deleted,
                   users_updated,
                   groups_added,
                   groups_deleted,
                   groups_updated)
