parameters: (filename, project_to_scan, reverse)
return_statement: return 0
docstring: Displays the project's dependencies.
docstring_summary: Displays the project's dependencies.
docstring_tokens: Displays the project s dependencies .
function: def sln_deps(filename, project_to_scan, reverse):
    """Displays the project's dependencies."""
    project_to_scan = project_to_scan.lower()
  
    projects = ScanSlnFile(filename)
  
    if reverse:
      # Inverse the dependencies map so they are displayed in the reverse order.
      # First, create a copy of the map.
      projects_reversed = copy.deepcopy(projects)
      for project_reversed in projects_reversed.itervalues():
        project_reversed.deps = []
      # Then, assign reverse dependencies.
      for project in projects.itervalues():
        for dep in project.deps:
          projects_reversed[dep].deps.append(project.guid)
      projects = projects_reversed
  
    # Print the results.
    for project in projects.itervalues():
      if project.type == FOLDER_GUID:
        continue
      if project_to_scan and project.name.lower() != project_to_scan:
        continue
      print project.name
      deps_name = [projects[d].name for d in project.deps]
      print "\n".join(str("  " + name) for name in sorted(deps_name,
                                                          key=str.lower))
    return 0
function_tokens: def sln_deps ( filename , project_to_scan , reverse ) : project_to_scan = project_to_scan . lower ( ) projects = ScanSlnFile ( filename ) if reverse : # Inverse the dependencies map so they are displayed in the reverse order. # First, create a copy of the map. projects_reversed = copy . deepcopy ( projects ) for project_reversed in projects_reversed . itervalues ( ) : project_reversed . deps = [ ] # Then, assign reverse dependencies. for project in projects . itervalues ( ) : for dep in project . deps : projects_reversed [ dep ] . deps . append ( project . guid ) projects = projects_reversed # Print the results. for project in projects . itervalues ( ) : if project . type == FOLDER_GUID : continue if project_to_scan and project . name . lower ( ) != project_to_scan : continue print project . name deps_name = [ projects [ d ] . name for d in project . deps ] print "\n" . join ( str ( "  " + name ) for name in sorted ( deps_name , key = str . lower ) ) return 0