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

"""
    apimaticcalculatorlatest

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


class PMs(object):

    """Implementation of the 'PMs' model.

    Property Manager model

    Attributes:
        id (int): ID of the property manager
        name (string): Name of the property manager’s company
        extra_name (string): Contact person
        email_address (string): Email of the property manager

    """

    # Create a mapping from Model property names to API property names
    _names = {
        "id":'id',
        "name":'name',
        "extra_name":'extraName',
        "email_address":'emailAddress'
    }

    def __init__(self,
                 id=None,
                 name=None,
                 extra_name=None,
                 email_address=None):
        """Constructor for the PMs class"""

        # Initialize members of the class
        self.id = id
        self.name = name
        self.extra_name = extra_name
        self.email_address = email_address


    @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
        id = dictionary.get('id')
        name = dictionary.get('name')
        extra_name = dictionary.get('extraName')
        email_address = dictionary.get('emailAddress')

        # Return an object of this model
        return cls(id,
                   name,
                   extra_name,
                   email_address)


