code: def list(self, **kwargs):
          
  
          # Duplicate data to avoid messing with what the user sent us
          data = kwargs.copy()
          if self.gitlab.per_page:
              data.setdefault('per_page', self.gitlab.per_page)
  
          # We get the attributes that need some special transformation
          types = getattr(self, '_types', {})
          if types:
              for attr_name, type_cls in types.items():
                  if attr_name in data.keys():
                      type_obj = type_cls(data[attr_name])
                      data[attr_name] = type_obj.get_for_api()
  
          # Allow to overwrite the path, handy for custom listings
          path = data.pop('path', self.path)
  
          obj = self.gitlab.http_list(path, **data)
          if isinstance(obj, list):
              return [self._obj_cls(self, item) for item in obj]
          else:
              return base.RESTObjectList(self, self._obj_cls, obj)
docs: Retrieve a list of objects.
  
          Args:
              all (bool): If True, return all the items, without pagination
              per_page (int): Number of items to retrieve per request
              page (int): ID of the page to return (starts with page 1)
              as_list (bool): If set to False and no pagination option is
                  defined, return a generator instead of a list
              **kwargs: Extra options to send to the server (e.g. sudo)
  
          Returns:
              list: The list of objects, or a generator if `as_list` is False
  
          Raises:
              GitlabAuthenticationError: If authentication is not correct
              GitlabListError: If the server cannot perform the request