|
Packit Service |
21c75c |
..
|
|
Packit Service |
21c75c |
Copyright (C) 2014-2018 Red Hat, Inc.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
This copyrighted material is made available to anyone wishing to use,
|
|
Packit Service |
21c75c |
modify, copy, or redistribute it subject to the terms and conditions of
|
|
Packit Service |
21c75c |
the GNU General Public License v.2, or (at your option) any later version.
|
|
Packit Service |
21c75c |
This program is distributed in the hope that it will be useful, but WITHOUT
|
|
Packit Service |
21c75c |
ANY WARRANTY expressed or implied, including the implied warranties of
|
|
Packit Service |
21c75c |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
|
|
Packit Service |
21c75c |
Public License for more details. You should have received a copy of the
|
|
Packit Service |
21c75c |
GNU General Public License along with this program; if not, write to the
|
|
Packit Service |
21c75c |
Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
|
|
Packit Service |
21c75c |
02110-1301, USA. Any Red Hat trademarks that are incorporated in the
|
|
Packit Service |
21c75c |
source code or documentation are not subject to the GNU General Public
|
|
Packit Service |
21c75c |
License and may only be used or replicated with the express permission of
|
|
Packit Service |
21c75c |
Red Hat, Inc.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
###################
|
|
Packit Service |
21c75c |
DNF API Reference
|
|
Packit Service |
21c75c |
###################
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
.. contents::
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
==============
|
|
Packit Service |
21c75c |
Introduction
|
|
Packit Service |
21c75c |
==============
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
The provided Python API to DNF is supposed to mainly allow writing the following two categories of programs:
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
1. :doc:`plugins <api_plugins>` to DNF which extend functionality of the system's DNF installation.
|
|
Packit Service |
21c75c |
2. extension applications that embed DNF (by importing its Python modules) to perform specific package management tasks.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
Please refer to the :doc:`use_cases` where you can find examples of API usage.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
.. NOTE::
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
The API consists of exactly those elements described in this document, items not documented here can change release to release. Opening a `bugzilla`_ if certain needed functionality is not exposed is the right thing to do.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
============
|
|
Packit Service |
21c75c |
Versioning
|
|
Packit Service |
21c75c |
============
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
DNF follows the Semantic Versioning as defined at http://semver.org/.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
This basically means that if your piece of software depends on e.g. DNF 1.1, the requirement can be specified as ``1.1 <= dnf < 2``. In other words, you can be sure that your software will be API-compatible with any later release of DNF until the next major version is issued. The same applies for the CLI compatibility.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
.. _deprecating-label:
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
Incompatible API changes are subject to our deprecation policy. Deprecated API items (classes, methods, etc.) are designated as such in the :doc:`release_notes`. The first release where support for such items can be dropped entirely must have, relative to the deprecating release, a higher major version number. DNF will log a warning when a deprecated item is used.
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
===========
|
|
Packit Service |
21c75c |
Contents
|
|
Packit Service |
21c75c |
===========
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
API Documentation Contents
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
.. toctree::
|
|
Packit Service |
21c75c |
:maxdepth: 2
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
api_common
|
|
Packit Service |
21c75c |
api_base
|
|
Packit Service |
21c75c |
api_exceptions
|
|
Packit Service |
21c75c |
api_conf
|
|
Packit Service |
21c75c |
api_repos
|
|
Packit Service |
21c75c |
api_sack
|
|
Packit Service |
21c75c |
api_queries
|
|
Packit Service |
21c75c |
api_selector
|
|
Packit Service |
21c75c |
api_package
|
|
Packit Service |
21c75c |
api_transaction
|
|
Packit Service |
21c75c |
api_comps
|
|
Packit Service |
21c75c |
api_plugins
|
|
Packit Service |
21c75c |
api_callback
|
|
Packit Service |
21c75c |
api_rpm
|
|
Packit Service |
21c75c |
api_cli
|
|
Packit Service |
21c75c |
api_module
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
Indices:
|
|
Packit Service |
21c75c |
|
|
Packit Service |
21c75c |
* :ref:`genindex`
|