paludis  Version 1.4.2
Public Member Functions | Protected Member Functions | List of all members
paludis::FakeInstalledRepository Class Reference

#include <fake_installed_repository.hh>

+ Inheritance diagram for paludis::FakeInstalledRepository:

Public Member Functions

virtual bool some_ids_might_support_action (const SupportsActionTestBase &) const
 
virtual bool some_ids_might_not_be_masked () const
 
virtual const bool is_unimportant () const
 
virtual const std::shared_ptr
< const MetadataValueKey
< std::string > > 
format_key () const
 
virtual const std::shared_ptr
< const MetadataValueKey
< FSPath > > 
location_key () const
 
virtual const std::shared_ptr
< const MetadataValueKey
< FSPath > > 
installed_root_key () const
 
virtual const std::shared_ptr
< const MetadataCollectionKey
< Map< std::string,
std::string > > > 
sync_host_key () const
 
virtual const std::shared_ptr
< const Set< std::string > > 
maybe_expand_licence_nonrecursively (const std::string &) const
 
- Public Member Functions inherited from paludis::FakeRepositoryBase
 ~FakeRepositoryBase ()
 
void add_category (const CategoryNamePart &)
 
void add_package (const QualifiedPackageName &)
 
std::shared_ptr< FakePackageIDadd_version (const QualifiedPackageName &, const VersionSpec &)
 
std::shared_ptr< FakePackageIDadd_version (const std::string &c, const std::string &p, const std::string &v)
 
virtual void invalidate ()
 
const Environmentenvironment () const
 
virtual std::shared_ptr< const
PackageIDSequence
package_ids (const QualifiedPackageName &, const RepositoryContentMayExcludes &) const PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual std::shared_ptr< const
QualifiedPackageNameSet
package_names (const CategoryNamePart &, const RepositoryContentMayExcludes &) const PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual std::shared_ptr< const
CategoryNamePartSet
category_names (const RepositoryContentMayExcludes &) const PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual bool has_package_named (const QualifiedPackageName &, const RepositoryContentMayExcludes &) const PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual bool has_category_named (const CategoryNamePart &, const RepositoryContentMayExcludes &) const PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual bool sync (const std::string &, const std::string &, const std::shared_ptr< OutputManager > &) const
 
virtual HookResult perform_hook (const Hook &hook, const std::shared_ptr< OutputManager > &)
 
virtual void populate_sets () const
 
- Public Member Functions inherited from paludis::Repository
virtual ~Repository ()
 
 Repository (const Repository &)=delete
 
Repositoryoperator= (const Repository &)=delete
 
const RepositoryName name () const PALUDIS_ATTRIBUTE((nothrow)) PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual std::shared_ptr< const
CategoryNamePartSet
unimportant_category_names (const RepositoryContentMayExcludes &repository_content_may_excludes) const
 
virtual std::shared_ptr< const
CategoryNamePartSet
category_names_containing_package (const PackageNamePart &p, const RepositoryContentMayExcludes &repository_content_may_excludes) const
 
virtual void regenerate_cache () const
 
virtual void purge_invalid_cache () const
 
virtual void can_drop_in_memory_cache () const
 
- Public Member Functions inherited from paludis::MetadataKeyHolder
MetadataConstIterator begin_metadata () const PALUDIS_ATTRIBUTE((warn_unused_result))
 
MetadataConstIterator end_metadata () const PALUDIS_ATTRIBUTE((warn_unused_result))
 
MetadataConstIterator find_metadata (const std::string &) const PALUDIS_ATTRIBUTE((warn_unused_result))
 
- Public Member Functions inherited from paludis::RepositoryDestinationInterface

Protected Member Functions

virtual bool is_suitable_destination_for (const std::shared_ptr< const PackageID > &) const PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual bool want_pre_post_phases () const PALUDIS_ATTRIBUTE((warn_unused_result))
 
virtual void merge (const MergeParams &)
 
- Protected Member Functions inherited from paludis::FakeRepositoryBase
 FakeRepositoryBase (const Environment *const env, const RepositoryName &name, const RepositoryCapabilities &caps)
 
virtual void need_keys_added () const
 
- Protected Member Functions inherited from paludis::Repository
 Repository (const Environment *const, const RepositoryName &, const RepositoryCapabilities &)
 
- Protected Member Functions inherited from paludis::MetadataKeyHolder
virtual void add_metadata_key (const std::shared_ptr< const MetadataKey > &) const
 
virtual void clear_metadata_keys () const
 

Basic operations

 FakeInstalledRepository (const FakeInstalledRepositoryParams &)
 
 ~FakeInstalledRepository ()
 

RepositoryFactory functions

static RepositoryName repository_factory_name (const Environment *const env, const std::function< std::string(const std::string &)> &)
 
static std::shared_ptr
< Repository
repository_factory_create (Environment *const env, const std::function< std::string(const std::string &)> &)
 
static std::shared_ptr< const
RepositoryNameSet
repository_factory_dependencies (const Environment *const env, const std::function< std::string(const std::string &)> &)
 

Additional Inherited Members

- Public Types inherited from paludis::MetadataKeyHolder
typedef WrappedForwardIterator
< MetadataConstIteratorTag,
const std::shared_ptr< const
MetadataKey > > 
MetadataConstIterator
 
- Public Attributes inherited from paludis::RepositoryCapabilities
NamedValue
< n::destination_interface,
RepositoryDestinationInterface * > 
destination_interface
 
NamedValue
< n::environment_variable_interface,
RepositoryEnvironmentVariableInterface * > 
environment_variable_interface
 
NamedValue
< n::manifest_interface,
RepositoryManifestInterface * > 
manifest_interface
 

Detailed Description

A fake repository for test cases, for installed packages.

Constructor & Destructor Documentation

paludis::FakeInstalledRepository::FakeInstalledRepository ( const FakeInstalledRepositoryParams )
Since
0.42

Member Function Documentation

virtual const std::shared_ptr<const MetadataValueKey<std::string> > paludis::FakeInstalledRepository::format_key ( ) const
virtual

The format_key, if non-zero, holds our repository's format. Repository implementations should not return zero here, but clients should still check.

Implements paludis::Repository.

virtual const std::shared_ptr<const MetadataValueKey<FSPath> > paludis::FakeInstalledRepository::installed_root_key ( ) const
virtual

The installed_root_key, if non-zero, specifies that we contain installed packages at the specified root.

This key is currently used in various places to determine whether a repository is an 'installed' repository or not.

Implements paludis::Repository.

virtual bool paludis::FakeInstalledRepository::is_suitable_destination_for ( const std::shared_ptr< const PackageID > &  ) const
protectedvirtual

Are we a suitable destination for the specified package?

Since
0.58 takes id by shared_ptr

Implements paludis::RepositoryDestinationInterface.

virtual const bool paludis::FakeInstalledRepository::is_unimportant ( ) const
virtual

Are we unimportant?

In disambiguation, anything gets preferred over packages from unimportant repositories.

Since
0.46

Implements paludis::Repository.

virtual const std::shared_ptr<const MetadataValueKey<FSPath> > paludis::FakeInstalledRepository::location_key ( ) const
virtual

The location_key, if non-zero, holds the file or directory containing our repository's data, the format of which depends on the value of format_key.

Implements paludis::Repository.

virtual const std::shared_ptr<const Set<std::string> > paludis::FakeInstalledRepository::maybe_expand_licence_nonrecursively ( const std::string &  ) const
virtual

Possibly expand a licence.

May return a null pointer, if we don't define any licence groups, or if the thing being passed in doesn't look like a licence group.

This should not be recursive.

Callers should Environment::expand_licence, not this method.

Since
0.66

Implements paludis::Repository.

virtual void paludis::FakeInstalledRepository::merge ( const MergeParams )
protectedvirtual

Merge a package.

Implements paludis::RepositoryDestinationInterface.

virtual bool paludis::FakeInstalledRepository::some_ids_might_not_be_masked ( ) const
virtual

Might some of our IDs be not masked?

Used to optimise various Generator and Filter queries.

Since
0.49

Implements paludis::Repository.

virtual bool paludis::FakeInstalledRepository::some_ids_might_support_action ( const SupportsActionTestBase ) const
virtual

Might some of our IDs support a particular action?

Used to optimise various Generator and Filter queries. If a repository doesn't support, say, InstallAction, a query can skip searching it entirely when looking for installable packages.

Implements paludis::Repository.

virtual const std::shared_ptr<const MetadataCollectionKey<Map<std::string, std::string> > > paludis::FakeInstalledRepository::sync_host_key ( ) const
virtual

The sync_host_key, if present, should have value containing the host against which a sync will be performed for each suffix.

This is used to avoid starting multiple parallel syncs against the same host.

Since
0.44
0.55 is a Map<std::string, std::string>.

Implements paludis::Repository.

virtual bool paludis::FakeInstalledRepository::want_pre_post_phases ( ) const
protectedvirtual

If true, pre and post install phases will be used when writing to this destination.

This should return true for 'real' filesystem destinations (whether or not root is /, if root merges are supported), and false for intermediate destinations such as binary repositories.

Implements paludis::RepositoryDestinationInterface.


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