parameters: (self, objects)
return_statement: return formatted_objects
docstring: Formats the objects and provides reference to list of layers in GeoApp
          resources.
  
          :param objects: GeoApp objects
docstring_summary: Formats the objects and provides reference to list of layers in GeoApp
          resources.
docstring_tokens: Formats the objects and provides reference to list of layers in GeoApp resources .
function: def format_objects(self, objects):
          """
          Formats the objects and provides reference to list of layers in GeoApp
          resources.
  
          :param objects: GeoApp objects
          """
          formatted_objects = []
          for obj in objects:
              # convert the object to a dict using the standard values.
              formatted_obj = model_to_dict(obj, fields=self.VALUES)
              username = obj.owner.get_username()
              full_name = (obj.owner.get_full_name() or username)
              formatted_obj['owner__username'] = username
              formatted_obj['owner_name'] = full_name
              if obj.category:
                  formatted_obj['category__gn_description'] = obj.category.gn_description
              if obj.group:
                  formatted_obj['group'] = obj.group
                  try:
                      formatted_obj['group_name'] = GroupProfile.objects.get(slug=obj.group.name)
                  except GroupProfile.DoesNotExist:
                      formatted_obj['group_name'] = obj.group
  
              formatted_obj['keywords'] = [k.name for k in obj.keywords.all()] if obj.keywords else []
              formatted_obj['regions'] = [r.name for r in obj.regions.all()] if obj.regions else []
  
              if 'site_url' not in formatted_obj or len(formatted_obj['site_url']) == 0:
                  formatted_obj['site_url'] = settings.SITEURL
  
              # Probe Remote Services
              formatted_obj['store_type'] = 'geoapp'
              formatted_obj['online'] = True
  
              formatted_objects.append(formatted_obj)
          return formatted_objects
function_tokens: def format_objects ( self , objects ) : formatted_objects = [ ] for obj in objects : # convert the object to a dict using the standard values. formatted_obj = model_to_dict ( obj , fields = self . VALUES ) username = obj . owner . get_username ( ) full_name = ( obj . owner . get_full_name ( ) or username ) formatted_obj [ 'owner__username' ] = username formatted_obj [ 'owner_name' ] = full_name if obj . category : formatted_obj [ 'category__gn_description' ] = obj . category . gn_description if obj . group : formatted_obj [ 'group' ] = obj . group try : formatted_obj [ 'group_name' ] = GroupProfile . objects . get ( slug = obj . group . name ) except GroupProfile . DoesNotExist : formatted_obj [ 'group_name' ] = obj . group formatted_obj [ 'keywords' ] = [ k . name for k in obj . keywords . all ( ) ] if obj . keywords else [ ] formatted_obj [ 'regions' ] = [ r . name for r in obj . regions . all ( ) ] if obj . regions else [ ] if 'site_url' not in formatted_obj or len ( formatted_obj [ 'site_url' ] ) == 0 : formatted_obj [ 'site_url' ] = settings . SITEURL # Probe Remote Services formatted_obj [ 'store_type' ] = 'geoapp' formatted_obj [ 'online' ] = True formatted_objects . append ( formatted_obj ) return formatted_objects