l.s.i.w.IArchiveSet(Interface) : interface documentation

Part of lp.soyuz.interfaces.webservice View In Hierarchy

Interface for ArchiveSet
Attribute title Title
Method empty_list There is no default content, but lazr.restful needs some anyway.
Method new Create a new archive.
Method get Return the IArchive with the given archive_id.
Method getByReference Return the IArchive with the given archive reference.
Method getPPAByDistributionAndOwnerName Return a single PPA.
Method getByDistroPurpose Return the IArchive with the given distribution and purpose.
Method getByDistroAndName Return the IArchive with the given distribution and name.
Method __iter__ Iterates over existent archives, including the main_archives.
Method getPPAOwnedByPerson Return the named PPA owned by person.
Method getPPAsForUser Return all PPAs the given user can participate.
Method getPPADistributionsForUser Return the `Distribution`s of all PPAs for the given user.
Method getPPAsPendingSigningKey Return all PPAs pending signing key generation.
Method getLatestPPASourcePublicationsForDistribution The latest 5 PPA source publications for a given distribution.
Method getMostActivePPAsForDistribution Return the 5 most active PPAs.
Method getArchivesForDistribution Return a list of all the archives for a distribution.
Method getPrivatePPAs Return a result set containing all private PPAs.
Method getPublicationsInArchives Return a result set of publishing records for the source package.
title =
Title
@collection_default_content()
def empty_list():
There is no default content, but lazr.restful needs some anyway.
def new(purpose, owner, name=None, displayname=None, distribution=None, description=None, enabled=True, require_virtualized=True, private=False, suppress_subscription_notifications=False, processors=None):
Create a new archive.

On named-ppa creation, the signing key for the default PPA for the
given owner will be used if it is present.

:param purpose: `ArchivePurpose`;
:param owner: `IPerson` owning the Archive;
:param name: optional text to be used as the archive name, if not
    given it uses the names defined in
    `IArchiveSet._getDefaultArchiveNameForPurpose`;
:param displayname: optional text that will be used as a reference
    to this archive in the UI. If not provided a default text
    (including the archive name and the owner displayname)  will be
    used.
:param distribution: optional `IDistribution` to which the archive
    will be attached;
:param description: optional text to be set as the archive
    description;
:param enabled: whether the archive shall be enabled post creation
:param require_virtualized: whether builds for the new archive shall
    be carried out on virtual builders
:param private: whether or not to make the PPA private
:param suppress_subscription_notifications: whether to suppress
    emails to subscribers about new subscriptions.
:param processors: list of `IProcessors` for which the archive should
    build. If omitted, processors with `build_by_default` will be used.

:return: an `IArchive` object.
:raises AssertionError if name is already taken within distribution.
def get(archive_id):
Return the IArchive with the given archive_id.
@call_with(True, REQUEST_USER)
@operation_parameters(TextLine(_('Archive reference string'), True))
@operation_returns_entry(IArchive)
@export_read_operation()
@operation_for_version('devel')
def getByReference(reference, check_permissions=False, user=None):
Return the IArchive with the given archive reference.
def getPPAByDistributionAndOwnerName(distribution, person_name, ppa_name):
Return a single PPA.
ParametersdistributionThe context IDistribution.
person_nameThe context IPerson.
ppa_nameThe name of the archive (PPA)
def getByDistroPurpose(distribution, purpose, name=None):
Return the IArchive with the given distribution and purpose.

It uses the default names defined in IArchiveSet._getDefaultArchiveNameForPurpose.

:raises AssertionError if used for with ArchivePurpose.PPA.

def getByDistroAndName(distribution, name):
Return the IArchive with the given distribution and name.
def __iter__():
Iterates over existent archives, including the main_archives.
def getPPAOwnedByPerson(person, name=None, statuses=None, has_packages=False):
Return the named PPA owned by person.

If the name is not supplied it will default to the first PPA that the person created.

ParameterspersonAn IPerson. Required.
nameThe PPA name. Optional.
statusesA list of statuses the PPAs must match. Optional.
has_packagesIf True will only select PPAs that have published source packages.
RaisesNoSuchPPAif the named PPA does not exist.
def getPPAsForUser(user):
Return all PPAs the given user can participate.

The result is ordered by PPA displayname.

def getPPADistributionsForUser(user):
Return the `Distribution`s of all PPAs for the given user.
def getPPAsPendingSigningKey():
Return all PPAs pending signing key generation.

The result is ordered by archive creation date.

def getLatestPPASourcePublicationsForDistribution(distribution):
The latest 5 PPA source publications for a given distribution.

Private PPAs are excluded from the result.

def getMostActivePPAsForDistribution(distribution):

Return the 5 most active PPAs.

The activity is currently measured by number of uploaded (published) sources for each PPA during the last 7 days.

Private PPAs are excluded from the result.

:return A list with up to 5 dictionaries containing the ppa 'title'
and the number of 'uploads' keys and corresponding values.
def getArchivesForDistribution(distribution, name=None, purposes=None, user=None, exclude_disabled=True):
Return a list of all the archives for a distribution.

This will return all the archives for the given distribution, with the following parameters:

Parametersdistributiontarget IDistribution
nameAn optional archive name which will further restrict the results to only those archives with this name.
purposesAn optional archive purpose or list of purposes with which to filter the results.
userAn optional IPerson who is requesting the archives, which is used to include private archives for which the user has permission. If it is not supplied, only public archives will be returned.
exclude_disabledWhether to exclude disabled archives.
ReturnsA queryset of all the archives for the given distribution matching the given params.
def getPrivatePPAs():
Return a result set containing all private PPAs.
def getPublicationsInArchives(source_package_name, archive_list, distribution):
Return a result set of publishing records for the source package.
Parameterssource_package_namean ISourcePackageName identifying the source package for which the publishings will be returned.
archive_lista list of at least one archive with which to restrict the search.
distributionthe distribution by which the results will be limited.
Returnsa resultset of the ISourcePackagePublishingHistory objects that are currently published in the given archives.
API Documentation for Launchpad, generated by pydoctor at 2019-05-22 00:00:12.