aboutsummaryrefslogtreecommitdiff
path: root/python
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-04-07 14:15:31 +0100
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2011-04-07 14:15:31 +0100
commit5bca2928c8047c1d34e35d8c167a7a6644b2515a (patch)
treef89de8dc9aac885067abea62dc1f5e8fcb04eea9 /python
parent4eb9754117cf6d1fe9985fc1950ffbaf943fcafc (diff)
downloadpaludis-5bca2928c8047c1d34e35d8c167a7a6644b2515a.tar.gz
paludis-5bca2928c8047c1d34e35d8c167a7a6644b2515a.tar.xz
Constraint -> Requirement
Diffstat (limited to 'python')
-rw-r--r--python/dep_spec.cc224
-rw-r--r--python/dep_spec.hh20
-rwxr-xr-xpython/dep_spec_TEST.py6
-rw-r--r--python/generator_TEST.py4
-rwxr-xr-xpython/mask_TEST.py2
-rw-r--r--python/package_dep_spec_constraint.cc154
-rw-r--r--python/paludis_python.hh2
-rw-r--r--python/paludis_python_so.cc2
8 files changed, 207 insertions, 207 deletions
diff --git a/python/dep_spec.cc b/python/dep_spec.cc
index 4898d54be..318fa9153 100644
--- a/python/dep_spec.cc
+++ b/python/dep_spec.cc
@@ -27,7 +27,7 @@
#include <paludis/environment.hh>
#include <paludis/user_dep_spec.hh>
#include <paludis/dep_spec_data.hh>
-#include <paludis/package_dep_spec_constraint.hh>
+#include <paludis/package_dep_spec_requirement.hh>
#include <paludis/version_spec.hh>
#include <paludis/version_operator.hh>
@@ -73,33 +73,33 @@ namespace paludis
template<>
struct Imp<PythonPackageDepSpec>
{
- std::shared_ptr<const NameConstraint> package_name_constraint;
- std::shared_ptr<const CategoryNamePartConstraint> category_name_part_constraint;
- std::shared_ptr<const PackageNamePartConstraint> package_name_part_constraint;
- std::shared_ptr<const VersionConstraintSequence> all_versions;
- std::shared_ptr<const AnySlotConstraint> any_slot;
- std::shared_ptr<const ExactSlotConstraint> exact_slot;
- std::shared_ptr<const InRepositoryConstraint> in_repository;
- std::shared_ptr<const FromRepositoryConstraint> from_repository;
- std::shared_ptr<const KeyConstraintSequence> all_keys;
- std::shared_ptr<const ChoiceConstraintSequence> all_choices;
+ std::shared_ptr<const NameRequirement> package_name_requirement;
+ std::shared_ptr<const CategoryNamePartRequirement> category_name_part_requirement;
+ std::shared_ptr<const PackageNamePartRequirement> package_name_part_requirement;
+ std::shared_ptr<const VersionRequirementSequence> all_versions;
+ std::shared_ptr<const AnySlotRequirement> any_slot;
+ std::shared_ptr<const ExactSlotRequirement> exact_slot;
+ std::shared_ptr<const InRepositoryRequirement> in_repository;
+ std::shared_ptr<const FromRepositoryRequirement> from_repository;
+ std::shared_ptr<const KeyRequirementSequence> all_keys;
+ std::shared_ptr<const ChoiceRequirementSequence> all_choices;
const std::string str;
Imp(
- const std::shared_ptr<const NameConstraint> & q,
- const std::shared_ptr<const CategoryNamePartConstraint> & c,
- const std::shared_ptr<const PackageNamePartConstraint> & p,
- const std::shared_ptr<const VersionConstraintSequence> & v,
- const std::shared_ptr<const AnySlotConstraint> & s,
- const std::shared_ptr<const ExactSlotConstraint> & xs,
- const std::shared_ptr<const InRepositoryConstraint> & ri,
- const std::shared_ptr<const FromRepositoryConstraint> & rf,
- const std::shared_ptr<const KeyConstraintSequence> & k,
- const std::shared_ptr<const ChoiceConstraintSequence> & a,
+ const std::shared_ptr<const NameRequirement> & q,
+ const std::shared_ptr<const CategoryNamePartRequirement> & c,
+ const std::shared_ptr<const PackageNamePartRequirement> & p,
+ const std::shared_ptr<const VersionRequirementSequence> & v,
+ const std::shared_ptr<const AnySlotRequirement> & s,
+ const std::shared_ptr<const ExactSlotRequirement> & xs,
+ const std::shared_ptr<const InRepositoryRequirement> & ri,
+ const std::shared_ptr<const FromRepositoryRequirement> & rf,
+ const std::shared_ptr<const KeyRequirementSequence> & k,
+ const std::shared_ptr<const ChoiceRequirementSequence> & a,
const std::string & st) :
- package_name_constraint(q),
- category_name_part_constraint(c),
- package_name_part_constraint(p),
+ package_name_requirement(q),
+ category_name_part_requirement(c),
+ package_name_part_requirement(p),
all_versions(v),
any_slot(s),
exact_slot(xs),
@@ -226,16 +226,16 @@ deep_copy(const std::shared_ptr<const T_> & x)
PythonPackageDepSpec::PythonPackageDepSpec(const PackageDepSpec & p) :
PythonStringDepSpec(p.text()),
_imp(
- p.package_name_constraint(),
- p.category_name_part_constraint(),
- p.package_name_part_constraint(),
- p.all_version_constraints(),
- p.any_slot_constraint(),
- p.exact_slot_constraint(),
- p.in_repository_constraint(),
- p.from_repository_constraint(),
- p.all_key_constraints(),
- p.all_choice_constraints(),
+ p.package_name_requirement(),
+ p.category_name_part_requirement(),
+ p.package_name_part_requirement(),
+ p.all_version_requirements(),
+ p.any_slot_requirement(),
+ p.exact_slot_requirement(),
+ p.in_repository_requirement(),
+ p.from_repository_requirement(),
+ p.all_key_requirements(),
+ p.all_choice_requirements(),
stringify(p))
{
}
@@ -243,16 +243,16 @@ PythonPackageDepSpec::PythonPackageDepSpec(const PackageDepSpec & p) :
PythonPackageDepSpec::PythonPackageDepSpec(const PythonPackageDepSpec & p) :
PythonStringDepSpec(p.text()),
_imp(
- p.package_name_constraint(),
- p.category_name_part_constraint(),
- p.package_name_part_constraint(),
- p.all_version_constraints(),
- p.any_slot_constraint(),
- p.exact_slot_constraint(),
- p.in_repository_constraint(),
- p.from_repository_constraint(),
- p.all_key_constraints(),
- p.all_choice_constraints(),
+ p.package_name_requirement(),
+ p.category_name_part_requirement(),
+ p.package_name_part_requirement(),
+ p.all_version_requirements(),
+ p.any_slot_requirement(),
+ p.exact_slot_requirement(),
+ p.in_repository_requirement(),
+ p.from_repository_requirement(),
+ p.all_key_requirements(),
+ p.all_choice_requirements(),
p.py_str())
{
}
@@ -265,46 +265,46 @@ PythonPackageDepSpec::operator PackageDepSpec() const
{
MutablePackageDepSpecData p({ });
- if (package_name_constraint())
- p.constrain_package(package_name_constraint()->name());
+ if (package_name_requirement())
+ p.require_package(package_name_requirement()->name());
- if (category_name_part_constraint())
- p.constrain_category_name_part(category_name_part_constraint()->name_part());
+ if (category_name_part_requirement())
+ p.require_category_name_part(category_name_part_requirement()->name_part());
- if (package_name_part_constraint())
- p.constrain_package_name_part(package_name_part_constraint()->name_part());
+ if (package_name_part_requirement())
+ p.require_package_name_part(package_name_part_requirement()->name_part());
- if (all_version_constraints())
+ if (all_version_requirements())
{
- for (auto i(all_version_constraints()->begin()), i_end(all_version_constraints()->end()) ;
+ for (auto i(all_version_requirements()->begin()), i_end(all_version_requirements()->end()) ;
i != i_end ; ++i)
- p.constrain_version((*i)->combiner(), (*i)->version_operator(), (*i)->version_spec());
+ p.require_version((*i)->combiner(), (*i)->version_operator(), (*i)->version_spec());
}
- if (any_slot_constraint())
- p.constrain_any_slot(any_slot_constraint()->locking());
+ if (any_slot_requirement())
+ p.require_any_slot(any_slot_requirement()->locking());
- if (exact_slot_constraint())
- p.constrain_exact_slot(exact_slot_constraint()->name(), exact_slot_constraint()->locked());
+ if (exact_slot_requirement())
+ p.require_exact_slot(exact_slot_requirement()->name(), exact_slot_requirement()->locked());
- if (in_repository_constraint())
- p.constrain_in_repository(in_repository_constraint()->name());
+ if (in_repository_requirement())
+ p.require_in_repository(in_repository_requirement()->name());
- if (from_repository_constraint())
- p.constrain_from_repository(from_repository_constraint()->name());
+ if (from_repository_requirement())
+ p.require_from_repository(from_repository_requirement()->name());
- if (all_choice_constraints())
+ if (all_choice_requirements())
{
- for (ChoiceConstraintSequence::ConstIterator i(all_choice_constraints()->begin()),
- i_end(all_choice_constraints()->end()) ; i != i_end ; ++i)
- p.constrain_choice(*i);
+ for (ChoiceRequirementSequence::ConstIterator i(all_choice_requirements()->begin()),
+ i_end(all_choice_requirements()->end()) ; i != i_end ; ++i)
+ p.require_choice(*i);
}
- if (all_key_constraints())
+ if (all_key_requirements())
{
- for (auto i(all_key_constraints()->begin()), i_end(all_key_constraints()->end()) ;
+ for (auto i(all_key_requirements()->begin()), i_end(all_key_requirements()->end()) ;
i != i_end ; ++i)
- p.constrain_key((*i)->key_type(), (*i)->key(), (*i)->operation(), (*i)->pattern());
+ p.require_key((*i)->key_type(), (*i)->key(), (*i)->operation(), (*i)->pattern());
}
return PackageDepSpec(p);
@@ -316,62 +316,62 @@ PythonPackageDepSpec::operator std::shared_ptr<PackageDepSpec>() const
return std::make_shared<PackageDepSpec>(*this);
}
-const std::shared_ptr<const NameConstraint>
-PythonPackageDepSpec::package_name_constraint() const
+const std::shared_ptr<const NameRequirement>
+PythonPackageDepSpec::package_name_requirement() const
{
- return _imp->package_name_constraint;
+ return _imp->package_name_requirement;
}
-const std::shared_ptr<const PackageNamePartConstraint>
-PythonPackageDepSpec::package_name_part_constraint() const
+const std::shared_ptr<const PackageNamePartRequirement>
+PythonPackageDepSpec::package_name_part_requirement() const
{
- return _imp->package_name_part_constraint;
+ return _imp->package_name_part_requirement;
}
-const std::shared_ptr<const CategoryNamePartConstraint>
-PythonPackageDepSpec::category_name_part_constraint() const
+const std::shared_ptr<const CategoryNamePartRequirement>
+PythonPackageDepSpec::category_name_part_requirement() const
{
- return _imp->category_name_part_constraint;
+ return _imp->category_name_part_requirement;
}
-const std::shared_ptr<const VersionConstraintSequence>
-PythonPackageDepSpec::all_version_constraints() const
+const std::shared_ptr<const VersionRequirementSequence>
+PythonPackageDepSpec::all_version_requirements() const
{
return _imp->all_versions;
}
-const std::shared_ptr<const AnySlotConstraint>
-PythonPackageDepSpec::any_slot_constraint() const
+const std::shared_ptr<const AnySlotRequirement>
+PythonPackageDepSpec::any_slot_requirement() const
{
return _imp->any_slot;
}
-const std::shared_ptr<const ExactSlotConstraint>
-PythonPackageDepSpec::exact_slot_constraint() const
+const std::shared_ptr<const ExactSlotRequirement>
+PythonPackageDepSpec::exact_slot_requirement() const
{
return _imp->exact_slot;
}
-const std::shared_ptr<const InRepositoryConstraint>
-PythonPackageDepSpec::in_repository_constraint() const
+const std::shared_ptr<const InRepositoryRequirement>
+PythonPackageDepSpec::in_repository_requirement() const
{
return _imp->in_repository;
}
-const std::shared_ptr<const FromRepositoryConstraint>
-PythonPackageDepSpec::from_repository_constraint() const
+const std::shared_ptr<const FromRepositoryRequirement>
+PythonPackageDepSpec::from_repository_requirement() const
{
return _imp->from_repository;
}
-const std::shared_ptr<const ChoiceConstraintSequence>
-PythonPackageDepSpec::all_choice_constraints() const
+const std::shared_ptr<const ChoiceRequirementSequence>
+PythonPackageDepSpec::all_choice_requirements() const
{
return _imp->all_choices;
}
-const std::shared_ptr<const KeyConstraintSequence>
-PythonPackageDepSpec::all_key_constraints() const
+const std::shared_ptr<const KeyRequirementSequence>
+PythonPackageDepSpec::all_key_requirements() const
{
return _imp->all_keys;
}
@@ -1207,40 +1207,40 @@ void expose_dep_spec()
bp::no_init
)
- .add_property("package_name_constraint", &PythonPackageDepSpec::package_name_constraint,
- "[ro] NameConstraint\n"
- "Qualified package name constraint (may be None)."
+ .add_property("package_name_requirement", &PythonPackageDepSpec::package_name_requirement,
+ "[ro] NameRequirement\n"
+ "Qualified package name requirement (may be None)."
)
- .add_property("package_name_part_constraint", &PythonPackageDepSpec::package_name_part_constraint,
- "[ro] CategoryNamePartConstraint\n"
- "Package name part constraint (may be None)"
+ .add_property("package_name_part_requirement", &PythonPackageDepSpec::package_name_part_requirement,
+ "[ro] CategoryNamePartRequirement\n"
+ "Package name part requirement (may be None)"
)
- .add_property("category_name_part_constraint", &PythonPackageDepSpec::category_name_part_constraint,
- "[ro] CategoryNamePartConstraint\n"
- "Category name part constraint (may be None)."
+ .add_property("category_name_part_requirement", &PythonPackageDepSpec::category_name_part_requirement,
+ "[ro] CategoryNamePartRequirement\n"
+ "Category name part requirement (may be None)."
)
- .add_property("exact_slot", &PythonPackageDepSpec::exact_slot_constraint,
- "[ro] ExactSlotConstraint\n"
- "Exact slot constraint (may be None)."
+ .add_property("exact_slot", &PythonPackageDepSpec::exact_slot_requirement,
+ "[ro] ExactSlotRequirement\n"
+ "Exact slot requirement (may be None)."
)
- .add_property("any_slot", &PythonPackageDepSpec::any_slot_constraint,
- "[ro] AnySlotConstraint\n"
- "Any slot constraint (may be None)."
+ .add_property("any_slot", &PythonPackageDepSpec::any_slot_requirement,
+ "[ro] AnySlotRequirement\n"
+ "Any slot requirement (may be None)."
)
- .add_property("in_repository_constraint", &PythonPackageDepSpec::in_repository_constraint,
- "[ro] InRepositoryConstraint\n"
- "In repository constraint (may be None)."
+ .add_property("in_repository_requirement", &PythonPackageDepSpec::in_repository_requirement,
+ "[ro] InRepositoryRequirement\n"
+ "In repository requirement (may be None)."
)
- .add_property("from_repository_constraint", &PythonPackageDepSpec::from_repository_constraint,
- "[ro] FromRepositoryConstraint\n"
- "From repository constraint (may be None)."
+ .add_property("from_repository_requirement", &PythonPackageDepSpec::from_repository_requirement,
+ "[ro] FromRepositoryRequirement\n"
+ "From repository requirement (may be None)."
)
#if 0
diff --git a/python/dep_spec.hh b/python/dep_spec.hh
index ab1b30e24..a6e407f37 100644
--- a/python/dep_spec.hh
+++ b/python/dep_spec.hh
@@ -172,16 +172,16 @@ namespace paludis
operator PackageDepSpec() const;
operator std::shared_ptr<PackageDepSpec>() const;
- const std::shared_ptr<const NameConstraint> package_name_constraint() const;
- const std::shared_ptr<const PackageNamePartConstraint> package_name_part_constraint() const;
- const std::shared_ptr<const CategoryNamePartConstraint> category_name_part_constraint() const;
- const std::shared_ptr<const VersionConstraintSequence> all_version_constraints() const;
- const std::shared_ptr<const InRepositoryConstraint> in_repository_constraint() const;
- const std::shared_ptr<const FromRepositoryConstraint> from_repository_constraint() const;
- const std::shared_ptr<const ExactSlotConstraint> exact_slot_constraint() const;
- const std::shared_ptr<const AnySlotConstraint> any_slot_constraint() const;
- const std::shared_ptr<const KeyConstraintSequence> all_key_constraints() const;
- const std::shared_ptr<const ChoiceConstraintSequence> all_choice_constraints() const;
+ const std::shared_ptr<const NameRequirement> package_name_requirement() const;
+ const std::shared_ptr<const PackageNamePartRequirement> package_name_part_requirement() const;
+ const std::shared_ptr<const CategoryNamePartRequirement> category_name_part_requirement() const;
+ const std::shared_ptr<const VersionRequirementSequence> all_version_requirements() const;
+ const std::shared_ptr<const InRepositoryRequirement> in_repository_requirement() const;
+ const std::shared_ptr<const FromRepositoryRequirement> from_repository_requirement() const;
+ const std::shared_ptr<const ExactSlotRequirement> exact_slot_requirement() const;
+ const std::shared_ptr<const AnySlotRequirement> any_slot_requirement() const;
+ const std::shared_ptr<const KeyRequirementSequence> all_key_requirements() const;
+ const std::shared_ptr<const ChoiceRequirementSequence> all_choice_requirements() const;
std::string py_str() const;
};
diff --git a/python/dep_spec_TEST.py b/python/dep_spec_TEST.py
index 476d7179d..da992cfe5 100755
--- a/python/dep_spec_TEST.py
+++ b/python/dep_spec_TEST.py
@@ -64,12 +64,12 @@ class TestCase_1_DepSpecs(unittest.TestCase):
def test_05_package(self):
self.get_depspecs()
- self.assertEqual(str(self.pds.package_name_constraint.name), "foo/bar")
+ self.assertEqual(str(self.pds.package_name_requirement.name), "foo/bar")
def test_06_in_from_repository(self):
self.get_depspecs()
- self.assertEqual(str(self.pds.in_repository_constraint.name), "testrepo")
- self.assertEqual(self.pds.from_repository_constraint, None)
+ self.assertEqual(str(self.pds.in_repository_requirement.name), "testrepo")
+ self.assertEqual(self.pds.from_repository_requirement, None)
### def test_09_additional_requirements(self):
### spec = parse_user_package_dep_spec("foo/monkey[foo]", UserPackageDepSpecOptions())
diff --git a/python/generator_TEST.py b/python/generator_TEST.py
index c1b690c5a..a35833b0b 100644
--- a/python/generator_TEST.py
+++ b/python/generator_TEST.py
@@ -35,8 +35,8 @@ class TestCase_01_Generator(unittest.TestCase):
self.assertEquals(str(Generator.Matches(parse_user_package_dep_spec("foo/bar",
env, []), MatchPackageOptions())), "packages matching foo/bar")
self.assertEquals(str(Generator.Matches(parse_user_package_dep_spec("foo/bar",
- env, []), [MatchPackageOption.IGNORE_CHOICE_CONSTRAINTS])),
- "packages matching foo/bar (ignoring choice constraints)")
+ env, []), [MatchPackageOption.IGNORE_CHOICE_REQUIREMENTS])),
+ "packages matching foo/bar (ignoring choice requirements)")
if __name__ == "__main__":
diff --git a/python/mask_TEST.py b/python/mask_TEST.py
index 40262ff86..5190afda5 100755
--- a/python/mask_TEST.py
+++ b/python/mask_TEST.py
@@ -98,7 +98,7 @@ class TestCase_01_Masks(unittest.TestCase):
self.assertEquals(m.key(), "A")
self.assertEquals(m.description(), "by association")
- self.assertEquals(m.associated_package_spec().package_name_constraint.name, "masked/repo")
+ self.assertEquals(m.associated_package_spec().package_name_requirement.name, "masked/repo")
elif os.environ.get("PALUDIS_ENABLE_VIRTUALS_REPOSITORY") != "no":
raise "oops"
diff --git a/python/package_dep_spec_constraint.cc b/python/package_dep_spec_constraint.cc
index 7385ec2e1..d794a3934 100644
--- a/python/package_dep_spec_constraint.cc
+++ b/python/package_dep_spec_constraint.cc
@@ -21,231 +21,231 @@
#include <python/paludis_python.hh>
#include <paludis/util/wrapped_forward_iterator-impl.hh>
#include <paludis/util/fs_path.hh>
-#include <paludis/package_dep_spec_constraint.hh>
+#include <paludis/package_dep_spec_requirement.hh>
using namespace paludis;
using namespace paludis::python;
namespace bp = boost::python;
-// For classes derived from PackageDepSpecConstraint
+// For classes derived from PackageDepSpecRequirement
template <typename C_>
-class class_package_dep_spec_constraint :
- public bp::class_<C_, std::shared_ptr<C_>, bp::bases<PackageDepSpecConstraint>, boost::noncopyable>
+class class_package_dep_spec_requirement :
+ public bp::class_<C_, std::shared_ptr<C_>, bp::bases<PackageDepSpecRequirement>, boost::noncopyable>
{
public:
template <class Init_>
- class_package_dep_spec_constraint(const std::string & name, const std::string & class_doc, Init_ initspec) :
- bp::class_<C_, std::shared_ptr<C_>, bp::bases<PackageDepSpecConstraint>, boost::noncopyable>(
+ class_package_dep_spec_requirement(const std::string & name, const std::string & class_doc, Init_ initspec) :
+ bp::class_<C_, std::shared_ptr<C_>, bp::bases<PackageDepSpecRequirement>, boost::noncopyable>(
name.c_str(), class_doc.c_str(), initspec)
{
bp::register_ptr_to_python<std::shared_ptr<const C_> >();
- bp::implicitly_convertible<std::shared_ptr<C_>, std::shared_ptr<PackageDepSpecConstraint> >();
+ bp::implicitly_convertible<std::shared_ptr<C_>, std::shared_ptr<PackageDepSpecRequirement> >();
}
};
-void expose_package_dep_spec_constraint()
+void expose_package_dep_spec_requirement()
{
/**
* Enums
*/
- enum_auto("KeyConstraintOperation", last_kco,
- "The operation for a KeyConstraint");
+ enum_auto("KeyRequirementOperation", last_kro,
+ "The operation for a KeyRequirement");
/**
- * PackageDepSpecConstraint
+ * PackageDepSpecRequirement
*/
- bp::register_ptr_to_python<std::shared_ptr<const PackageDepSpecConstraint> >();
- bp::implicitly_convertible<std::shared_ptr<PackageDepSpecConstraint>,
- std::shared_ptr<const PackageDepSpecConstraint> >();
- bp::class_<PackageDepSpecConstraint, boost::noncopyable>
+ bp::register_ptr_to_python<std::shared_ptr<const PackageDepSpecRequirement> >();
+ bp::implicitly_convertible<std::shared_ptr<PackageDepSpecRequirement>,
+ std::shared_ptr<const PackageDepSpecRequirement> >();
+ bp::class_<PackageDepSpecRequirement, boost::noncopyable>
(
- "PackageDepSpecConstraint",
- "Base class for a constraint for a PackageDepSpec.",
+ "PackageDepSpecRequirement",
+ "Base class for a requirement for a PackageDepSpec.",
bp::no_init
)
;
/**
- * NameConstraint
+ * NameRequirement
*/
- class_package_dep_spec_constraint<NameConstraint>
+ class_package_dep_spec_requirement<NameRequirement>
(
- "NameConstraint",
- "A cat/pkg constraint for a PackageDepSpec.",
+ "NameRequirement",
+ "A cat/pkg requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("name", &NameConstraint::name,
+ .add_property("name", &NameRequirement::name,
"[RO] The cat/pkg in question"
)
;
/**
- * PackageNamePartConstraint
+ * PackageNamePartRequirement
*/
- class_package_dep_spec_constraint<PackageNamePartConstraint>
+ class_package_dep_spec_requirement<PackageNamePartRequirement>
(
- "PackageNamePartConstraint",
- "A /pkg constraint for a PackageDepSpec.",
+ "PackageNamePartRequirement",
+ "A /pkg requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("name_part", &PackageNamePartConstraint::name_part,
+ .add_property("name_part", &PackageNamePartRequirement::name_part,
"[RO] The /pkg in question"
)
;
/**
- * CategoryNamePartConstraint
+ * CategoryNamePartRequirement
*/
- class_package_dep_spec_constraint<CategoryNamePartConstraint>
+ class_package_dep_spec_requirement<CategoryNamePartRequirement>
(
- "CategoryNamePartConstraint",
- "A cat/ constraint for a PackageDepSpec.",
+ "CategoryNamePartRequirement",
+ "A cat/ requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("name_part", &CategoryNamePartConstraint::name_part,
+ .add_property("name_part", &CategoryNamePartRequirement::name_part,
"[RO] The cat/ in question"
)
;
/**
- * InRepositoryConstraint
+ * InRepositoryRequirement
*/
- class_package_dep_spec_constraint<InRepositoryConstraint>
+ class_package_dep_spec_requirement<InRepositoryRequirement>
(
- "InRepositoryConstraint",
- "A ::repo constraint for a PackageDepSpec.",
+ "InRepositoryRequirement",
+ "A ::repo requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("name", &InRepositoryConstraint::name,
+ .add_property("name", &InRepositoryRequirement::name,
"[RO] The ::repo name in question"
)
;
/**
- * FromRepositoryConstraint
+ * FromRepositoryRequirement
*/
- class_package_dep_spec_constraint<FromRepositoryConstraint>
+ class_package_dep_spec_requirement<FromRepositoryRequirement>
(
- "FromRepositoryConstraint",
- "A ::repo-> constraint for a PackageDepSpec.",
+ "FromRepositoryRequirement",
+ "A ::repo-> requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("name", &FromRepositoryConstraint::name,
+ .add_property("name", &FromRepositoryRequirement::name,
"[RO] The ::repo-> name in question"
)
;
/**
- * InstalledAtPathConstraint
+ * InstalledAtPathRequirement
*/
- class_package_dep_spec_constraint<InstalledAtPathConstraint>
+ class_package_dep_spec_requirement<InstalledAtPathRequirement>
(
- "InstalledAtPathConstraint",
- "A ::/ constraint for a PackageDepSpec.",
+ "InstalledAtPathRequirement",
+ "A ::/ requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("path", &InstalledAtPathConstraint::path,
+ .add_property("path", &InstalledAtPathRequirement::path,
"[RO] The ::/ path in question"
)
;
/**
- * InstallableToPathConstraint
+ * InstallableToPathRequirement
*/
- class_package_dep_spec_constraint<InstallableToPathConstraint>
+ class_package_dep_spec_requirement<InstallableToPathRequirement>
(
- "InstalledableToPathConstraint",
- "A ::/? constraint for a PackageDepSpec.",
+ "InstalledableToPathRequirement",
+ "A ::/? requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("path", &InstallableToPathConstraint::path,
+ .add_property("path", &InstallableToPathRequirement::path,
"[RO] The ::/? path in question"
)
- .add_property("include_masked", &InstallableToPathConstraint::include_masked,
+ .add_property("include_masked", &InstallableToPathRequirement::include_masked,
"[RO] Whether to include masked, as per ::/??"
)
;
/**
- * InstallableToRepositoryConstraint
+ * InstallableToRepositoryRequirement
*/
- class_package_dep_spec_constraint<InstallableToRepositoryConstraint>
+ class_package_dep_spec_requirement<InstallableToRepositoryRequirement>
(
- "InstalledableToPathConstraint",
- "A ::/? constraint for a PackageDepSpec.",
+ "InstalledableToPathRequirement",
+ "A ::/? requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("name", &InstallableToRepositoryConstraint::name,
+ .add_property("name", &InstallableToRepositoryRequirement::name,
"[RO] The ::repo? in question"
)
- .add_property("include_masked", &InstallableToRepositoryConstraint::include_masked,
+ .add_property("include_masked", &InstallableToRepositoryRequirement::include_masked,
"[RO] Whether to include masked, as per ::repo??"
)
;
/**
- * AnySlotConstraint
+ * AnySlotRequirement
*/
- class_package_dep_spec_constraint<AnySlotConstraint>
+ class_package_dep_spec_requirement<AnySlotRequirement>
(
- "AnySlotConstraint",
- "A :* or := constraint for a PackageDepSpec.",
+ "AnySlotRequirement",
+ "A :* or := requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("locking", &AnySlotConstraint::locking,
+ .add_property("locking", &AnySlotRequirement::locking,
"[RO] Are we locking (:= rather than :*)?"
)
;
/**
- * ExactSlotConstraint
+ * ExactSlotRequirement
*/
- class_package_dep_spec_constraint<ExactSlotConstraint>
+ class_package_dep_spec_requirement<ExactSlotRequirement>
(
- "ExactSlotConstraint",
- "A :slot or :=slot constraint for a PackageDepSpec.",
+ "ExactSlotRequirement",
+ "A :slot or :=slot requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("locked", &ExactSlotConstraint::locked,
+ .add_property("locked", &ExactSlotRequirement::locked,
"[RO] Are we locked (:=blah)?"
)
- .add_property("name", &ExactSlotConstraint::name,
+ .add_property("name", &ExactSlotRequirement::name,
"[RO] The slot name"
)
;
/**
- * KeyConstraint
+ * KeyRequirement
*/
- class_package_dep_spec_constraint<KeyConstraint>
+ class_package_dep_spec_requirement<KeyRequirement>
(
- "KeyConstraint",
- "A [.key=value] constraint for a PackageDepSpec.",
+ "KeyRequirement",
+ "A [.key=value] requirement for a PackageDepSpec.",
bp::no_init
)
- .add_property("key", &KeyConstraint::key,
+ .add_property("key", &KeyRequirement::key,
"[RO] The key"
)
- .add_property("pattern", &KeyConstraint::pattern,
+ .add_property("pattern", &KeyRequirement::pattern,
"[RO] The pattern"
)
- .add_property("operation", &KeyConstraint::operation,
+ .add_property("operation", &KeyRequirement::operation,
"[RO] The operation"
)
;
diff --git a/python/paludis_python.hh b/python/paludis_python.hh
index da8dcddad..5df480097 100644
--- a/python/paludis_python.hh
+++ b/python/paludis_python.hh
@@ -188,7 +188,7 @@ void expose_mask() PALUDIS_VISIBLE;
void expose_match_package() PALUDIS_VISIBLE;
void expose_metadata_key() PALUDIS_VISIBLE;
void expose_name() PALUDIS_VISIBLE;
-void expose_package_dep_spec_constraint() PALUDIS_VISIBLE;
+void expose_package_dep_spec_requirement() PALUDIS_VISIBLE;
void expose_package_id() PALUDIS_VISIBLE;
void expose_repository() PALUDIS_VISIBLE;
void expose_selection() PALUDIS_VISIBLE;
diff --git a/python/paludis_python_so.cc b/python/paludis_python_so.cc
index dad35d9d5..179a11907 100644
--- a/python/paludis_python_so.cc
+++ b/python/paludis_python_so.cc
@@ -36,7 +36,7 @@ BOOST_PYTHON_MODULE(paludis)
expose_fs_path();
expose_contents();
expose_filter(); /* must be before dep_spec */
- expose_package_dep_spec_constraint();
+ expose_package_dep_spec_requirement();
expose_dep_spec();
expose_dep_label();
expose_name();