aboutsummaryrefslogtreecommitdiff
path: root/paludis/repositories/e/info_metadata_key.cc
diff options
context:
space:
mode:
authorAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2009-01-18 23:55:50 +0000
committerAvatar Ciaran McCreesh <ciaran.mccreesh@googlemail.com> 2009-01-18 23:55:50 +0000
commitb12a4f151e0c16e18c08de5929922e4cd4d35165 (patch)
treecd410e5e465c10881752a718734554547d039e8d /paludis/repositories/e/info_metadata_key.cc
parentcfbe6ed8eb60a9096d32856a8442a477137edb96 (diff)
downloadpaludis-b12a4f151e0c16e18c08de5929922e4cd4d35165.tar.gz
paludis-b12a4f151e0c16e18c08de5929922e4cd4d35165.tar.xz
Make metadata key general methods pure virtual.
Diffstat (limited to 'paludis/repositories/e/info_metadata_key.cc')
-rw-r--r--paludis/repositories/e/info_metadata_key.cc44
1 files changed, 39 insertions, 5 deletions
diff --git a/paludis/repositories/e/info_metadata_key.cc b/paludis/repositories/e/info_metadata_key.cc
index 8bd84eb96..32ae6b833 100644
--- a/paludis/repositories/e/info_metadata_key.cc
+++ b/paludis/repositories/e/info_metadata_key.cc
@@ -1,7 +1,7 @@
/* vim: set sw=4 sts=4 et foldmethod=syntax : */
/*
- * Copyright (c) 2008 Ciaran McCreesh
+ * Copyright (c) 2008, 2009 Ciaran McCreesh
*
* 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
@@ -85,9 +85,7 @@ namespace paludis
}
InfoVarsMetadataKey::InfoVarsMetadataKey(const std::tr1::shared_ptr<const FSEntrySequence> & f) :
- MetadataCollectionKey<Set<std::string> >("info_vars", "Variable information names", mkt_internal),
- PrivateImplementationPattern<InfoVarsMetadataKey>(new Implementation<InfoVarsMetadataKey>(f)),
- _imp(PrivateImplementationPattern<InfoVarsMetadataKey>::_imp)
+ PrivateImplementationPattern<InfoVarsMetadataKey>(new Implementation<InfoVarsMetadataKey>(f))
{
}
@@ -121,10 +119,27 @@ InfoVarsMetadataKey::value() const
return _imp->value;
}
+const std::string
+InfoVarsMetadataKey::raw_name() const
+{
+ return "info_vars";
+}
+
+const std::string
+InfoVarsMetadataKey::human_name() const
+{
+ return "Variable information names";
+}
+
+MetadataKeyType
+InfoVarsMetadataKey::type() const
+{
+ return mkt_internal;
+}
+
InfoPkgsMetadataKey::InfoPkgsMetadataKey(const Environment * const e,
const std::tr1::shared_ptr<const FSEntrySequence> & f,
const ERepository * const r) :
- MetadataSectionKey("info_pkgs", "Package information", mkt_normal),
PrivateImplementationPattern<InfoPkgsMetadataKey>(new Implementation<InfoPkgsMetadataKey>(e, f, r)),
_imp(PrivateImplementationPattern<InfoPkgsMetadataKey>::_imp)
{
@@ -205,6 +220,25 @@ InfoVarsMetadataKey::pretty_print_flat(const Formatter<std::string> & f) const
return join(value()->begin(), value()->end(), " ", std::tr1::bind(&format_string, _1, f));
}
+const std::string
+InfoPkgsMetadataKey::raw_name() const
+{
+ return "info_pkgs";
+}
+
+const std::string
+InfoPkgsMetadataKey::human_name() const
+{
+ return "Package information";
+}
+
+MetadataKeyType
+InfoPkgsMetadataKey::type() const
+{
+ return mkt_internal;
+}
+
+
template class PrivateImplementationPattern<InfoPkgsMetadataKey>;
template class PrivateImplementationPattern<InfoVarsMetadataKey>;