aboutsummaryrefslogtreecommitdiff
path: root/paludis/name-fwd.hh
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-05-16 11:03:29 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2007-05-16 11:03:29 +0000
commitc4cf902f5610a1a42a27c9a08340ed35e08178a6 (patch)
tree193d58900d544a5f63a11c43852d38076cf4dac7 /paludis/name-fwd.hh
parent8801cefb2d3e916481bc021516663bea9667dc6d (diff)
downloadpaludis-c4cf902f5610a1a42a27c9a08340ed35e08178a6.tar.gz
paludis-c4cf902f5610a1a42a27c9a08340ed35e08178a6.tar.xz
More fwd headers. Split out PortageRepository layout logic
Diffstat (limited to 'paludis/name-fwd.hh')
-rw-r--r--paludis/name-fwd.hh194
1 files changed, 194 insertions, 0 deletions
diff --git a/paludis/name-fwd.hh b/paludis/name-fwd.hh
new file mode 100644
index 0000000..80ffb4c
--- /dev/null
+++ b/paludis/name-fwd.hh
@@ -0,0 +1,194 @@
+/* vim: set sw=4 sts=4 et foldmethod=syntax : */
+
+/*
+ * Copyright (c) 2005, 2006, 2007 Ciaran McCreesh <ciaranm@ciaranm.org>
+ *
+ * This file is part of the Paludis package manager. Paludis is free software;
+ * you can redistribute it and/or modify it under the terms of the GNU General
+ * Public License version 2, as published by the Free Software Foundation.
+ *
+ * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
+ * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
+ * details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
+ * Place, Suite 330, Boston, MA 02111-1307 USA
+ */
+
+#ifndef PALUDIS_GUARD_PALUDIS_NAME_FWD_HH
+#define PALUDIS_GUARD_PALUDIS_NAME_FWD_HH 1
+
+#include <paludis/util/validated-fwd.hh>
+#include <paludis/util/collection-fwd.hh>
+#include <paludis/util/attributes.hh>
+#include <string>
+
+namespace paludis
+{
+ class PackageNamePartError;
+ class PackageNamePartValidator;
+
+ /**
+ * A PackageNamePart holds a std::string that is a valid name for the
+ * package part of a QualifiedPackageName.
+ *
+ * \ingroup grpnames
+ */
+ typedef Validated<std::string, PackageNamePartValidator> PackageNamePart;
+
+ /**
+ * Holds a set of PackageNamePart instances.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<PackageNamePart> PackageNamePartCollection;
+
+ class CategoryNamePartError;
+ class CategoryNamePartValidator;
+
+ /**
+ * A CategoryNamePart holds a std::string that is a valid name for the
+ * category part of a QualifiedPackageName.
+ *
+ * \ingroup grpnames
+ */
+ typedef Validated<std::string, CategoryNamePartValidator> CategoryNamePart;
+
+ /**
+ * Holds a set of CategoryNamePart instances.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<CategoryNamePart> CategoryNamePartCollection;
+
+ class UseFlagNameError;
+ class IUseFlagNameError;
+ class UseFlagNameValidator;
+
+ /**
+ * A UseFlagName holds a std::string that is a valid name for a USE flag.
+ *
+ * \ingroup grpnames
+ */
+ typedef Validated<std::string, UseFlagNameValidator> UseFlagName;
+
+ /**
+ * A collection of UseFlagName instances.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<UseFlagName> UseFlagNameCollection;
+
+#include <paludis/name-se.hh>
+
+ class QualifiedPackageName;
+ class IUseFlag;
+
+ /**
+ * Output a QualifiedPackageName to a stream.
+ *
+ * \ingroup grpnames
+ */
+ std::ostream & operator<< (std::ostream &, const QualifiedPackageName &) PALUDIS_VISIBLE;
+
+ /**
+ * Output an IUseFlag to a stream.
+ *
+ * \ingroup grpnames
+ */
+ std::ostream & operator<< (std::ostream &, const IUseFlag &) PALUDIS_VISIBLE;
+
+ /**
+ * Holds a collection of QualifiedPackageName instances.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<QualifiedPackageName> QualifiedPackageNameCollection;
+
+ class QualifiedPackageNameError;
+
+ inline const QualifiedPackageName
+ operator+ (const CategoryNamePart & c, const PackageNamePart & p) PALUDIS_ATTRIBUTE((warn_unused_result));
+
+ class SlotNameError;
+ class SlotNameValidator;
+
+ /**
+ * A SlotName holds a std::string that is a valid name for a SLOT.
+ *
+ * \ingroup grpnames
+ */
+ typedef Validated<std::string, SlotNameValidator> SlotName;
+
+ class RepositoryNameError;
+ class RepositoryNameValidator;
+
+ /**
+ * A RepositoryName holds a std::string that is a valid name for a
+ * Repository.
+ *
+ * \ingroup grpnames
+ */
+ typedef Validated<std::string, RepositoryNameValidator, comparison_mode::EqualityComparisonTag> RepositoryName;
+
+ /**
+ * Holds a collection of RepositoryName instances.
+ *
+ * \ingroup grpnames
+ */
+ typedef SequentialCollection<RepositoryName> RepositoryNameCollection;
+
+ class RepositoryNameComparator;
+
+ class KeywordNameValidator;
+ class KeywordNameError;
+
+ /**
+ * A KeywordName holds a std::string that is a valid name for a KEYWORD.
+ *
+ * \ingroup grpnames
+ */
+ typedef Validated<std::string, KeywordNameValidator> KeywordName;
+
+ /**
+ * Holds a collection of KeywordName instances.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<KeywordName> KeywordNameCollection;
+
+ class SetNameValidator;
+ class SetNameError;
+
+ /**
+ * A SetName holds a std::string that is a valid name for a set.
+ *
+ * \ingroup grpnames
+ */
+ typedef Validated<std::string, SetNameValidator> SetName;
+
+ /**
+ * A collection of set names.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<SetName> SetNameCollection;
+
+ /**
+ * A collection of use flags.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<IUseFlag> IUseFlagCollection;
+
+ /**
+ * A collection of inherited packages.
+ *
+ * \ingroup grpnames
+ */
+ typedef SortedCollection<std::string> InheritedCollection;
+}
+
+#endif