====================
Finding dependencies
====================

.. automodule:: sumatra.dependency_finder

For users of the API, the principal function of interest is the following.

.. autofunction:: find_dependencies

This function returns a list of :class:`Dependency` objects. There is a
different :class:`Dependency` subclass for each programming language, but all
have the following attributes:

.. autoclass:: sumatra.dependency_finder.core.BaseDependency
   :members:
   :undoc-members:

If you are interested in improving the dependency finder for an existing
program/language, or in adding a dependency finder for a new program or language,
you may be interested in the following.


Language-independent heuristics and utilities
---------------------------------------------

.. currentmodule:: sumatra.dependency_finder.core

.. autofunction:: find_versions

.. autofunction:: find_versions_from_versioncontrol

.. autofunction:: find_file

Python
------

.. currentmodule:: sumatra.dependency_finder.python

.. autofunction:: find_versions_by_attribute

.. autofunction:: find_versions_from_egg

.. autofunction:: find_imported_packages

.. autofunction:: find_dependencies


.. autoclass: Dependency
   :members:
   :undoc-members:
   :inherited-members:
   :show-inheritance:


Matlab
------

.. currentmodule:: sumatra.dependency_finder.matlab

.. autofunction:: find_dependencies

.. autofunction:: save_dependencies

.. autoclass: Dependency
   :members:
   :undoc-members:
   :inherited-members:
   :show-inheritance:

NEURON
------

.. currentmodule:: sumatra.dependency_finder.neuron

.. autofunction:: find_xopened_files

.. autofunction:: find_loaded_files

.. autofunction:: find_dependencies

.. autoclass: Dependency
   :members:
   :undoc-members:
   :inherited-members:
   :show-inheritance:


GENESIS
-------

.. currentmodule:: sumatra.dependency_finder.genesis

.. autofunction:: find_included_files

.. autofunction:: find_dependencies

.. autoclass: Dependency
   :members:
   :undoc-members:
   :inherited-members:
   :show-inheritance:

R
--

.. currentmodule:: sumatra.dependency_finder.r

.. autofunction:: find_dependencies
