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

"""
cookiesapi

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


class StoreOrdering(object):

    """Implementation of the 'StoreOrdering' model.

    Describes order submission and menu information for a given Cookies
    store.

    Attributes:
        platform (string): Ordering platform in use by a Cookies store.
        store_id (string): Ordering platform ID in use by a Cookies store
            (public).
        enabled (bool): Whether online ordering is enabled for a given Cookies
            store.

    """

    # Create a mapping from Model property names to API property names
    _names = {
        "platform": 'platform',
        "store_id": 'storeId',
        "enabled": 'enabled'
    }

    def __init__(self,
                 platform=None,
                 store_id=None,
                 enabled=None):
        """Constructor for the StoreOrdering class"""

        # Initialize members of the class
        self.platform = platform
        self.store_id = store_id
        self.enabled = enabled

    @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
        platform = dictionary.get('platform')
        store_id = dictionary.get('storeId')
        enabled = dictionary.get('enabled')

        # Return an object of this model
        return cls(platform,
                   store_id,
                   enabled)
