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

"""
billbeeapi

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


class RechnungsdruckWebAppControllersApiSearchControllerProductResult(object):

    """Implementation of the 'Rechnungsdruck.WebApp.Controllers.Api.SearchController.ProductResult' model.

    TODO: type model description here.

    Attributes:
        id (long|int): TODO: type description here.
        short_text (string): TODO: type description here.
        sku (string): TODO: type description here.
        tags (string): TODO: type description here.

    """

    # Create a mapping from Model property names to API property names
    _names = {
        "id": 'Id',
        "short_text": 'ShortText',
        "sku": 'SKU',
        "tags": 'Tags'
    }

    def __init__(self,
                 id=None,
                 short_text=None,
                 sku=None,
                 tags=None):
        """Constructor for the RechnungsdruckWebAppControllersApiSearchControllerProductResult class"""

        # Initialize members of the class
        self.id = id
        self.short_text = short_text
        self.sku = sku
        self.tags = tags

    @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')
        short_text = dictionary.get('ShortText')
        sku = dictionary.get('SKU')
        tags = dictionary.get('Tags')

        # Return an object of this model
        return cls(id,
                   short_text,
                   sku,
                   tags)
