Qucs-S S-parameter Viewer & RF Synthesis Tools
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | Protected Member Functions | Protected Attributes | Properties | List of all members
pip._vendor.distlib.database.DistributionPath Class Reference
Inheritance diagram for pip._vendor.distlib.database.DistributionPath:
Inheritance graph
[legend]
Collaboration diagram for pip._vendor.distlib.database.DistributionPath:
Collaboration graph
[legend]

Public Member Functions

 __init__ (self, path=None, include_egg=False)
 
 clear_cache (self)
 
 distinfo_dirname (cls, name, version)
 
 get_distributions (self)
 
 get_distribution (self, name)
 
 provides_distribution (self, name, version=None)
 
 get_file_path (self, name, relative_path)
 
 get_exported_entries (self, category, name=None)
 

Public Attributes

 path
 

Protected Member Functions

 _get_cache_enabled (self)
 
 _set_cache_enabled (self, value)
 
 _yield_distributions (self)
 
 _generate_cache (self)
 

Protected Attributes

 _include_dist
 
 _include_egg
 
 _cache
 
 _cache_egg
 
 _cache_enabled
 
 _scheme
 

Properties

 cache_enabled = property(_get_cache_enabled, _set_cache_enabled)
 

Detailed Description

Represents a set of distributions installed on a path (typically sys.path).

Constructor & Destructor Documentation

◆ __init__()

pip._vendor.distlib.database.DistributionPath.__init__ (   self,
  path = None,
  include_egg = False 
)
Create an instance from a path, optionally including legacy (distutils/
setuptools/distribute) distributions.
:param path: The path to use, as a list of directories. If not specified,
             sys.path is used.
:param include_egg: If True, this instance will look for and return legacy
                    distributions as well as those based on PEP 376.

Member Function Documentation

◆ _generate_cache()

pip._vendor.distlib.database.DistributionPath._generate_cache (   self)
protected
Scan the path for distributions and populate the cache with
those that are found.

◆ _yield_distributions()

pip._vendor.distlib.database.DistributionPath._yield_distributions (   self)
protected
Yield .dist-info and/or .egg(-info) distributions.

◆ clear_cache()

pip._vendor.distlib.database.DistributionPath.clear_cache (   self)
Clears the internal cache.

◆ distinfo_dirname()

pip._vendor.distlib.database.DistributionPath.distinfo_dirname (   cls,
  name,
  version 
)
The *name* and *version* parameters are converted into their
filename-escaped form, i.e. any ``'-'`` characters are replaced
with ``'_'`` other than the one in ``'dist-info'`` and the one
separating the name from the version number.

:parameter name: is converted to a standard distribution name by replacing
                 any runs of non- alphanumeric characters with a single
                 ``'-'``.
:type name: string
:parameter version: is converted to a standard version string. Spaces
                    become dots, and all other non-alphanumeric characters
                    (except dots) become dashes, with runs of multiple
                    dashes condensed to a single dash.
:type version: string
:returns: directory name
:rtype: string

◆ get_distribution()

pip._vendor.distlib.database.DistributionPath.get_distribution (   self,
  name 
)
Looks for a named distribution on the path.

This function only returns the first result found, as no more than one
value is expected. If nothing is found, ``None`` is returned.

:rtype: :class:`InstalledDistribution`, :class:`EggInfoDistribution`
        or ``None``

◆ get_distributions()

pip._vendor.distlib.database.DistributionPath.get_distributions (   self)
Provides an iterator that looks for distributions and returns
:class:`InstalledDistribution` or
:class:`EggInfoDistribution` instances for each one of them.

:rtype: iterator of :class:`InstalledDistribution` and
        :class:`EggInfoDistribution` instances

◆ get_exported_entries()

pip._vendor.distlib.database.DistributionPath.get_exported_entries (   self,
  category,
  name = None 
)
Return all of the exported entries in a particular category.

:param category: The category to search for entries.
:param name: If specified, only entries with that name are returned.

◆ get_file_path()

pip._vendor.distlib.database.DistributionPath.get_file_path (   self,
  name,
  relative_path 
)
Return the path to a resource file.

◆ provides_distribution()

pip._vendor.distlib.database.DistributionPath.provides_distribution (   self,
  name,
  version = None 
)
Iterates over all distributions to find which distributions provide *name*.
If a *version* is provided, it will be used to filter the results.

This function only returns the first result found, since no more than
one values are expected. If the directory is not found, returns ``None``.

:parameter version: a version specifier that indicates the version
                    required, conforming to the format in ``PEP-345``

:type name: string
:type version: string

The documentation for this class was generated from the following file: