parameters: ()
docstring: This only takes the top level groups currently.
docstring_summary: This only takes the top level groups currently.
docstring_tokens: This only takes the top level groups currently .
function: def gatherGroups():
          """This only takes the top level groups currently."""
          ab = ABAddressBook.sharedAddressBook()
          groups = ab.groups()
          if not groups.count(): return
          fd = open("my/groups.json", "w")
          for group in groups:
              json.dump({"id":group.valueForProperty_(kABUIDProperty)[:-9], "name":group.name()}, fd)
              fd.write("\n")
function_tokens: def gatherGroups ( ) : ab = ABAddressBook . sharedAddressBook ( ) groups = ab . groups ( ) if not groups . count ( ) : return fd = open ( "my/groups.json" , "w" ) for group in groups : json . dump ( { "id" : group . valueForProperty_ ( kABUIDProperty ) [ : - 9 ] , "name" : group . name ( ) } , fd ) fd . write ( "\n" )