|
paludis Version 3.0.2
The one true package mangler
|
#include <package_id.hh>
Public Member Functions | |
| virtual void | can_drop_in_memory_cache () const |
| MetadataConstIterator | begin_metadata () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
| MetadataConstIterator | end_metadata () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
| IteratorRange< MetadataConstIterator > | metadata () const |
| MetadataConstIterator | find_metadata (const std::string &) const PALUDIS_ATTRIBUTE((warn_unused_result)) |
Protected Member Functions | |
| virtual void | add_mask (const std::shared_ptr< const Mask > &) const |
| virtual void | add_overridden_mask (const std::shared_ptr< const OverriddenMask > &) const |
| virtual void | need_masks_added () const =0 |
| 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 |
| virtual void | need_keys_added () const =0 |
Masks | |
| typedef WrappedForwardIterator< MasksConstIteratorTag, const std::shared_ptr< const Mask > > | MasksConstIterator |
| MasksConstIterator | begin_masks () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
| MasksConstIterator | end_masks () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
| IteratorRange< MasksConstIterator > | masks () const |
| bool | masked () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
Overridden masks | |
| typedef WrappedForwardIterator< OverriddenMasksConstIteratorTag, const std::shared_ptr< const OverriddenMask > > | OverriddenMasksConstIterator |
| OverriddenMasksConstIterator | begin_overridden_masks () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
| OverriddenMasksConstIterator | end_overridden_masks () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
| IteratorRange< OverriddenMasksConstIterator > | overridden_masks () const |
Basic operations | |
| std::size_t | hash () const PALUDIS_ATTRIBUTE((warn_unused_result)) |
Name related operations | |
| virtual const std::string | canonical_form (const PackageIDCanonicalForm) const =0 |
| virtual const QualifiedPackageName | name () const =0 |
| virtual const VersionSpec | version () const =0 |
| virtual const RepositoryName | repository_name () const =0 |
| virtual PackageDepSpec | uniquely_identifying_spec () const =0 |
Specific metadata keys | |
| virtual const std::shared_ptr< const MetadataValueKey< Slot > > | slot_key () const =0 |
| virtual const std::shared_ptr< const MetadataCollectionKey< KeywordNameSet > > | keywords_key () const =0 |
| virtual const std::shared_ptr< const MetadataSpecTreeKey< DependencySpecTree > > | dependencies_key () const =0 |
| virtual const std::shared_ptr< const MetadataSpecTreeKey< DependencySpecTree > > | build_dependencies_key () const =0 |
| virtual const std::shared_ptr< const MetadataSpecTreeKey< DependencySpecTree > > | run_dependencies_key () const =0 |
| virtual const std::shared_ptr< const MetadataSpecTreeKey< DependencySpecTree > > | post_dependencies_key () const =0 |
| virtual const std::shared_ptr< const MetadataSpecTreeKey< FetchableURISpecTree > > | fetches_key () const =0 |
| virtual const std::shared_ptr< const MetadataSpecTreeKey< SimpleURISpecTree > > | homepage_key () const =0 |
| virtual const std::shared_ptr< const MetadataValueKey< std::string > > | short_description_key () const =0 |
| virtual const std::shared_ptr< const MetadataValueKey< std::string > > | long_description_key () const =0 |
| virtual const std::shared_ptr< const MetadataTimeKey > | installed_time_key () const =0 |
| virtual const std::shared_ptr< const MetadataCollectionKey< Set< std::string > > > | from_repositories_key () const =0 |
| virtual const std::shared_ptr< const MetadataValueKey< FSPath > > | fs_location_key () const =0 |
| virtual const std::shared_ptr< const MetadataValueKey< std::shared_ptr< const Choices > > > | choices_key () const =0 |
| virtual const std::shared_ptr< const MetadataCollectionKey< Set< std::string > > > | behaviours_key () const =0 |
Actions | |
| virtual bool | supports_action (const SupportsActionTestBase &) const PALUDIS_ATTRIBUTE((warn_unused_result))=0 |
| virtual void | perform_action (Action &) const =0 |
| virtual const std::shared_ptr< const Contents > | contents () const =0 |
Extra comparisons | |
| virtual bool | arbitrary_less_than_comparison (const PackageID &) const PALUDIS_ATTRIBUTE((warn_unused_result))=0 |
| virtual std::size_t | extra_hash_value () const PALUDIS_ATTRIBUTE((warn_unused_result))=0 |
Additional Inherited Members | |
| typedef WrappedForwardIterator< MetadataConstIteratorTag, const std::shared_ptr< const MetadataKey > > | MetadataConstIterator |
A PackageID represents a unique package version in a particular Repository.
All PackageID instances have some basic identification data:
It should be noted that the above together are not sufficient to uniquely identify a package. Some repositories support multiple slots per version of a package, and some repositories support additional affixes that prevent a package from being uniquely identifiable merely by the above.
PackageID instances also have:
A PackageID instance may support certain actions, which are represented via an Action subclass instance.
|
protectedvirtual |
Add a new Mask.
|
protectedvirtual |
Add a new OverriddenMask.
|
pure virtual |
Perform an arbitrary less than comparison on another PackageID.
Used by PackageIDSetComparator and operator==. This function should not be used by anything else.
This function will only be called if the other PackageID has the same name, version and repository as this. If this is not enough to uniquely identify an ID (e.g. if there is an affix, or if multiple slots per version are allowed), then this function's implementation must differentiate appropriately.
Implemented in paludis::FakePackageID.
References arbitrary_less_than_comparison(), and PALUDIS_ATTRIBUTE.
Referenced by arbitrary_less_than_comparison().
|
pure virtual |
The behaviours_key may contain strings indicating that the PackageID behaves in a particular way.
Strings with recognised meanings currently are:
Implemented in paludis::FakePackageID.
References behaviours_key().
Referenced by behaviours_key().
|
pure virtual |
The build_dependencies_key, if non-zero, indicates a package's build-time dependencies.
Implemented in paludis::FakePackageID.
References build_dependencies_key().
Referenced by build_dependencies_key().
|
virtual |
Allow the PackageID to drop any memory-cached metadata it holds.
References can_drop_in_memory_cache().
Referenced by can_drop_in_memory_cache().
|
pure virtual |
Return our canonical string representation.
This method (which is called by paludis::stringify()) should be used when outputting a PackageID or a PackageID's version. Some repositories need to display additional information to identify a package, so outputting merely the name and / or version may be insufficient.
Implemented in paludis::FakePackageID.
References canonical_form().
Referenced by canonical_form().
|
pure virtual |
The choices_key, if non-zero, contains zero or more MetadataValueKey<std::shared_ptr<const Choice> > child keys holding choice information for this ID.
Implemented in paludis::FakePackageID.
References choices_key().
Referenced by choices_key().
|
pure virtual |
The contents, if non-zero, contains the contents of a package. For installed packages, this means the files installed; for installable packages, this means the files that will be installed (if known, which it may be for some binary packages).
Implemented in paludis::FakePackageID.
References contents(), and PALUDIS_ATTRIBUTE.
Referenced by contents().
|
pure virtual |
The dependencies_key, if non-zero, provides all of a package's dependencies.
If dependencies_key is used, the client should ignore build_dependencies_key, run_dependencies_key and post_dependencies_key.
Repositories that support this key must also provide the old split out keys.
Implemented in paludis::FakePackageID.
References dependencies_key().
Referenced by dependencies_key().
|
pure virtual |
Provide any additional hash information for a PackageID.
The standard PackageID hash incorporates the repository name, the package name and the version of the package. If this function is defined, its value is also used when determining a hash. This can provide increased performance if a repository uses affixes or multiple slots per version.
Implemented in paludis::FakePackageID.
References extra_hash_value(), and PALUDIS_ATTRIBUTE.
Referenced by extra_hash_value().
|
pure virtual |
The fetches_key, if non-zero, indicates files that have to be fetched in order to install a package.
Implemented in paludis::FakePackageID.
References fetches_key().
Referenced by fetches_key().
|
pure virtual |
The from_repositories key, if non-zero, contains the set of repositories that the ID is 'from'. An ID can be 'from' multiple repositories if, for example, it was built via a binary package.
Implemented in paludis::FakePackageID.
References from_repositories_key().
Referenced by from_repositories_key().
|
pure virtual |
The fs_location_key, if non-zero, indicates the filesystem location (for example, the ebuild file or VDB directory) that best describes the location of a PackageID.
Implemented in paludis::FakePackageID.
References fs_location_key().
Referenced by fs_location_key().
|
pure virtual |
The homepage_key, if non-zero, describes a package's homepages.
Implemented in paludis::FakePackageID.
References homepage_key().
Referenced by homepage_key().
|
pure virtual |
The installed_time_key, if non-zero, contains the time a package was installed. It affects dependency resolution if DepList is using dl_reinstall_scm_daily or dl_reinstall_scm_weekly.
Implemented in paludis::FakePackageID.
References installed_time_key().
Referenced by installed_time_key().
|
pure virtual |
The keywords_key, if non-zero, is used by FindUnusedPackagesTask to determine whether a package is unused.
Implemented in paludis::FakePackageID.
References keywords_key().
Referenced by keywords_key().
|
pure virtual |
The long_description_key, if non-zero, provides a long description of a package.
Implemented in paludis::FakePackageID.
References long_description_key().
Referenced by long_description_key().
| bool paludis::PackageID::masked | ( | ) | const |
Do we have any effective masks? Equivalent to begin_masks() != end_masks().
References masked(), and PALUDIS_ATTRIBUTE.
Referenced by masked().
|
pure virtual |
What is our package name?
Use canonical_form instead for outputting.
Implemented in paludis::FakePackageID.
References name().
Referenced by name().
|
protectedpure virtual |
This method will be called before any of the mask iteration methods does its work. It can be used by subclasses to implement as-needed loading of masks.
Implemented in paludis::FakePackageID.
References PALUDIS_ATTRIBUTE.
|
pure virtual |
Perform the specified action.
Implemented in paludis::FakePackageID.
References perform_action().
Referenced by perform_action().
|
pure virtual |
The post_dependencies_key, if non-zero, indicates a package's post-merge dependencies.
Implemented in paludis::FakePackageID.
References post_dependencies_key().
Referenced by post_dependencies_key().
|
pure virtual |
What is our owning repository?
Implemented in paludis::FakePackageID.
References repository_name().
Referenced by repository_name().
|
pure virtual |
The run_dependencies_key, if non-zero, indicates a package's run-time dependencies.
Implemented in paludis::FakePackageID.
References run_dependencies_key().
Referenced by run_dependencies_key().
|
pure virtual |
The short_description_key, if non-zero, provides a short (no more than a few hundred characters) description of a package.
Implemented in paludis::FakePackageID.
References short_description_key().
Referenced by short_description_key().
|
pure virtual |
The slot, if specified, controls whether the package can be installed in parallel with other versions of the same package.
Implemented in paludis::FakePackageID.
References slot_key().
Referenced by slot_key().
|
pure virtual |
Do we support a particular action?
Attempting to call perform_action with an unsupported action type will lead to an UnsupportedActionError. However, in performance critical code and in situations where creating a full Action subclass instance is non-trivial, supports_action is much simpler.
Implemented in paludis::FakePackageID.
References PALUDIS_ATTRIBUTE, and supports_action().
Referenced by supports_action().
|
pure virtual |
Return a PackageDepSpec that uniquely identifies us.
When stringified, can be turned back into an equivalent unique PackageDepSpec by using parse_user_package_dep_spec.
Implemented in paludis::FakePackageID.
References uniquely_identifying_spec().
Referenced by uniquely_identifying_spec().
|
pure virtual |
What is our package version?
Use canonical_form instead for outputting.
Implemented in paludis::FakePackageID.
References version().
Referenced by version().