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

"""
    apimaticcalculatorlatest

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


class PetPolicy(object):

    """Implementation of the 'PetPolicy' model.

    TODO: type model description here.

    Attributes:
        allowed_pets (AllowedPetsTypeEnum): TODO: type description here.
        charge_pets (string): Charge parking. Example: “Free”, “$ 100”.

    """

    # Create a mapping from Model property names to API property names
    _names = {
        "allowed_pets":'allowedPets',
        "charge_pets":'chargePets'
    }

    def __init__(self,
                 allowed_pets=None,
                 charge_pets=None):
        """Constructor for the PetPolicy class"""

        # Initialize members of the class
        self.allowed_pets = allowed_pets
        self.charge_pets = charge_pets


    @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
        allowed_pets = dictionary.get('allowedPets')
        charge_pets = dictionary.get('chargePets')

        # Return an object of this model
        return cls(allowed_pets,
                   charge_pets)


