text: # coding: utf-8
  
  """
      qTest Manager API Version 8.6 - 9.1
  
      qTest Manager API Version 8.6 - 9.1
  
      OpenAPI spec version: 8.6 - 9.1
      
      Generated by: https://github.com/swagger-api/swagger-codegen.git
  """
  
  
  from pprint import pformat
  from six import iteritems
  import re
  
  
  class ModuleResource(object):
      """
      NOTE: This class is auto generated by the swagger code generator program.
      Do not edit the class manually.
      """
      def __init__(self, links=None, id=None, name=None, order=None, pid=None, created_date=None, last_modified_date=None, parent_id=None, description=None, shared=False, children=None):
          """
          ModuleResource - a model defined in Swagger
  
          :param dict swaggerTypes: The key is attribute name
                                    and the value is attribute type.
          :param dict attributeMap: The key is attribute name
                                    and the value is json key in definition.
          """
          self.swagger_types = {
              'links': 'list[Link]',
              'id': 'int',
              'name': 'str',
              'order': 'int',
              'pid': 'str',
              'created_date': 'datetime',
              'last_modified_date': 'datetime',
              'parent_id': 'int',
              'description': 'str',
              'shared': 'bool',
              'children': 'list[ModuleResource]'
          }
  
          self.attribute_map = {
              'links': 'links',
              'id': 'id',
              'name': 'name',
              'order': 'order',
              'pid': 'pid',
              'created_date': 'created_date',
              'last_modified_date': 'last_modified_date',
              'parent_id': 'parent_id',
              'description': 'description',
              'shared': 'shared',
              'children': 'children'
          }
  
          self._links = links
          self._id = id
          self._name = name
          self._order = order
          self._pid = pid
          self._created_date = created_date
          self._last_modified_date = last_modified_date
          self._parent_id = parent_id
          self._description = description
          self._shared = shared
          self._children = children
  
      @property
      def links(self):
          """
          Gets the links of this ModuleResource.
  
          :return: The links of this ModuleResource.
          :rtype: list[Link]
          """
          return self._links
  
      @links.setter
      def links(self, links):
          """
          Sets the links of this ModuleResource.
  
          :param links: The links of this ModuleResource.
          :type: list[Link]
          """
  
          self._links = links
  
      @property
      def id(self):
          """
          Gets the id of this ModuleResource.
          ID of the Module
  
          :return: The id of this ModuleResource.
          :rtype: int
          """
          return self._id
  
      @id.setter
      def id(self, id):
          """
          Sets the id of this ModuleResource.
          ID of the Module
  
          :param id: The id of this ModuleResource.
          :type: int
          """
  
          self._id = id
  
      @property
      def name(self):
          """
          Gets the name of this ModuleResource.
          Name of the Module
  
          :return: The name of this ModuleResource.
          :rtype: str
          """
          return self._name
  
      @name.setter
      def name(self, name):
          """
          Sets the name of this ModuleResource.
          Name of the Module
  
          :param name: The name of this ModuleResource.
          :type: str
          """
          if name is not None and len(name) > 500:
              raise ValueError("Invalid value for `name`, length must be less than or equal to `500`")
          if name is not None and len(name) < 1:
              raise ValueError("Invalid value for `name`, length must be greater than or equal to `1`")
  
          self._name = name
  
      @property
      def order(self):
          """
          Gets the order of this ModuleResource.
          Display order of the Module
  
          :return: The order of this ModuleResource.
          :rtype: int
          """
          return self._order
  
      @order.setter
      def order(self, order):
          """
          Sets the order of this ModuleResource.
          Display order of the Module
  
          :param order: The order of this ModuleResource.
          :type: int
          """
  
          self._order = order
  
      @property
      def pid(self):
          """
          Gets the pid of this ModuleResource.
          PID of the Module
  
          :return: The pid of this ModuleResource.
          :rtype: str
          """
          return self._pid
  
      @pid.setter
      def pid(self, pid):
          """
          Sets the pid of this ModuleResource.
          PID of the Module
  
          :param pid: The pid of this ModuleResource.
          :type: str
          """
  
          self._pid = pid
  
      @property
      def created_date(self):
          """
          Gets the created_date of this ModuleResource.
  
          :return: The created_date of this ModuleResource.
          :rtype: datetime
          """
          return self._created_date
  
      @created_date.setter
      def created_date(self, created_date):
          """
          Sets the created_date of this ModuleResource.
  
          :param created_date: The created_date of this ModuleResource.
          :type: datetime
          """
  
          self._created_date = created_date
  
      @property
      def last_modified_date(self):
          """
          Gets the last_modified_date of this ModuleResource.
  
          :return: The last_modified_date of this ModuleResource.
          :rtype: datetime
          """
          return self._last_modified_date
  
      @last_modified_date.setter
      def last_modified_date(self, last_modified_date):
          """
          Sets the last_modified_date of this ModuleResource.
  
          :param last_modified_date: The last_modified_date of this ModuleResource.
          :type: datetime
          """
  
          self._last_modified_date = last_modified_date
  
      @property
      def parent_id(self):
          """
          Gets the parent_id of this ModuleResource.
          Parent Module of the Module
  
          :return: The parent_id of this ModuleResource.
          :rtype: int
          """
          return self._parent_id
  
      @parent_id.setter
      def parent_id(self, parent_id):
          """
          Sets the parent_id of this ModuleResource.
          Parent Module of the Module
  
          :param parent_id: The parent_id of this ModuleResource.
          :type: int
          """
  
          self._parent_id = parent_id
  
      @property
      def description(self):
          """
          Gets the description of this ModuleResource.
          Description of the Module
  
          :return: The description of this ModuleResource.
          :rtype: str
          """
          return self._description
  
      @description.setter
      def description(self, description):
          """
          Sets the description of this ModuleResource.
          Description of the Module
  
          :param description: The description of this ModuleResource.
          :type: str
          """
  
          self._description = description
  
      @property
      def shared(self):
          """
          Gets the shared of this ModuleResource.
          Is shared or not
  
          :return: The shared of this ModuleResource.
          :rtype: bool
          """
          return self._shared
  
      @shared.setter
      def shared(self, shared):
          """
          Sets the shared of this ModuleResource.
          Is shared or not
  
          :param shared: The shared of this ModuleResource.
          :type: bool
          """
  
          self._shared = shared
  
      @property
      def children(self):
          """
          Gets the children of this ModuleResource.
          Arrays of child module
  
          :return: The children of this ModuleResource.
          :rtype: list[ModuleResource]
          """
          return self._children
  
      @children.setter
      def children(self, children):
          """
          Sets the children of this ModuleResource.
          Arrays of child module
  
          :param children: The children of this ModuleResource.
          :type: list[ModuleResource]
          """
  
          self._children = children
  
      def to_dict(self):
          """
          Returns the model properties as a dict
          """
          result = {}
  
          for attr, _ in iteritems(self.swagger_types):
              value = getattr(self, attr)
              if isinstance(value, list):
                  result[attr] = list(map(
                      lambda x: x.to_dict() if hasattr(x, "to_dict") else x,
                      value
                  ))
              elif hasattr(value, "to_dict"):
                  result[attr] = value.to_dict()
              elif isinstance(value, dict):
                  result[attr] = dict(map(
                      lambda item: (item[0], item[1].to_dict())
                      if hasattr(item[1], "to_dict") else item,
                      value.items()
                  ))
              else:
                  result[attr] = value
  
          return result
  
      def to_str(self):
          """
          Returns the string representation of the model
          """
          return pformat(self.to_dict())
  
      def __repr__(self):
          """
          For `print` and `pprint`
          """
          return self.to_str()
  
      def __eq__(self, other):
          """
          Returns true if both objects are equal
          """
          if not isinstance(other, ModuleResource):
              return False
  
          return self.__dict__ == other.__dict__
  
      def __ne__(self, other):
          """
          Returns true if both objects are not equal
          """
          return not self == other
  