From c67366ef18b3daf1df153646b5ffa93dd0f000c2 Mon Sep 17 00:00:00 2001 From: Klaus Kaempf Date: Thu, 2 Feb 2006 21:52:42 +0000 Subject: [PATCH] - remove SelectionsParser.cc - rename SelectionSelFileParser -> SelectionTagFileParser - add Pattern parser --- zypp/source/susetags/Makefile.am | 8 +- zypp/source/susetags/PatternTagFileParser.cc | 162 +++++++++++++++++++++ zypp/source/susetags/PatternTagFileParser.h | 67 +++++++++ ...nSelFileParser.cc => SelectionTagFileParser.cc} | 15 +- ...ionSelFileParser.h => SelectionTagFileParser.h} | 14 +- zypp/source/susetags/SelectionsParser.cc | 136 ----------------- zypp/source/susetags/SuseTagsImpl.cc | 35 ++++- zypp/source/susetags/SuseTagsPatternImpl.cc | 62 ++++++++ zypp/source/susetags/SuseTagsPatternImpl.h | 97 ++++++++++++ 9 files changed, 441 insertions(+), 155 deletions(-) create mode 100644 zypp/source/susetags/PatternTagFileParser.cc create mode 100644 zypp/source/susetags/PatternTagFileParser.h rename zypp/source/susetags/{SelectionSelFileParser.cc => SelectionTagFileParser.cc} (92%) rename zypp/source/susetags/{SelectionSelFileParser.h => SelectionTagFileParser.h} (87%) delete mode 100644 zypp/source/susetags/SelectionsParser.cc create mode 100644 zypp/source/susetags/SuseTagsPatternImpl.cc create mode 100644 zypp/source/susetags/SuseTagsPatternImpl.h diff --git a/zypp/source/susetags/Makefile.am b/zypp/source/susetags/Makefile.am index 2902fbc..6fe5fe4 100644 --- a/zypp/source/susetags/Makefile.am +++ b/zypp/source/susetags/Makefile.am @@ -11,8 +11,10 @@ sourceinclude_HEADERS = \ PackagesParser.h\ SuseTagsImpl.h \ SuseTagsSelectionImpl.h \ + SuseTagsPatternImpl.h \ SuseTagsPackageImpl.h \ - SelectionSelFileParser.h \ + SelectionTagFileParser.h \ + PatternTagFileParser.h \ ProductMetadataParser.h \ MediaMetadataParser.h \ MediaPatchesMetadataParser.h @@ -25,8 +27,10 @@ lib@PACKAGE@_source_susetags_la_SOURCES = \ PackagesParser.cc \ SuseTagsImpl.cc \ SuseTagsSelectionImpl.cc \ + SuseTagsPatternImpl.cc \ SuseTagsPackageImpl.cc \ - SelectionSelFileParser.cc \ + SelectionTagFileParser.cc \ + PatternTagFileParser.cc \ ProductMetadataParser.cc \ MediaMetadataParser.cc \ MediaPatchesMetadataParser.cc diff --git a/zypp/source/susetags/PatternTagFileParser.cc b/zypp/source/susetags/PatternTagFileParser.cc new file mode 100644 index 0000000..ada7032 --- /dev/null +++ b/zypp/source/susetags/PatternTagFileParser.cc @@ -0,0 +1,162 @@ +/*---------------------------------------------------------------------\ +| ____ _ __ __ ___ | +| |__ / \ / / . \ . \ | +| / / \ V /| _/ _/ | +| / /__ | | | | | | | +| /_____||_| |_| |_| | +| | +\---------------------------------------------------------------------*/ +/** \file zypp/parser/tagfile/PatternTagFileParser.cc + * +*/ +#include +#include +#include + +#include +#include + +#include "zypp/base/Logger.h" +#include "zypp/base/PtrTypes.h" +#include "zypp/base/String.h" +#include "zypp/CapFactory.h" + +#include "zypp/source/susetags/PatternTagFileParser.h" +#include + +#undef ZYPP_BASE_LOGGER_LOGGROUP +#define ZYPP_BASE_LOGGER_LOGGROUP "PatternsTagFileParser" + +using namespace std; +using namespace boost; + +/////////////////////////////////////////////////////////////////// +namespace zypp +{ ///////////////////////////////////////////////////////////////// + /////////////////////////////////////////////////////////////////// + namespace source + { ///////////////////////////////////////////////////////////////// + /////////////////////////////////////////////////////////////////// + namespace susetags + { ///////////////////////////////////////////////////////////////// + + Pattern::Ptr parsePattern( const Pathname & file_r ) + { + PatternTagFileParser p; + p.parse( file_r ); + return p.result; + + } + + PatternTagFileParser::PatternTagFileParser() + { + selImpl = shared_ptr(new SuseTagsPatternImpl); + } + + void PatternTagFileParser::consume( const SingleTag &tag ) + { + if ( tag.name == "Sum" ) + { + selImpl->_summary.setText(tag.value, LanguageCode(tag.modifier)); + } + else if ( tag.name == "Ver" ) + { + selImpl->_parser_version = tag.value; + } + else if ( tag.name == "Pat" ) + { + std::string line = tag.value; + std::vector words; + str::split( line, std::back_inserter(words), " " ); + XXX << "[" << words[0] << "]" << "[" << words[1] << "]" << "[" << words[2] << "]" << "[" << words[3] << "]" << std::endl; + selImpl->_name = words[0]; + selImpl->_version = words[1]; + selImpl->_release = words[2]; + selImpl->_arch = words[3]; + } + else if ( tag.name == "Vis" ) + { + selImpl->_visible = (tag.value == "true") ? true : false; + } + else if ( tag.name == "Cat" ) + { + selImpl->_category = tag.value; + } + else if ( tag.name == "Ord" ) + { + selImpl->_order = tag.value; + } + } + + void PatternTagFileParser::consume( const MultiTag &tag ) + { + if ( tag.name == "Req" ) + { + selImpl->_requires = tag.values; + } + else if ( tag.name == "Rec" ) + { + selImpl->_recommends = tag.values; + } + else if ( tag.name == "Con" ) + { + selImpl->_conflicts = tag.values; + } + else if ( tag.name == "Prq" ) // package requires + { + selImpl->_pkgrequires = tag.values; + } + else if ( tag.name == "Prc" ) // package recommends + { + selImpl->_pkgrecommends = tag.values; + } + } + + void PatternTagFileParser::endParse() + { + #warning FIXME how to insert the specific language packages + CapFactory _f; + Dependencies _deps; + + for (std::list::const_iterator it = selImpl->_recommends.begin(); it != selImpl->_recommends.end(); it++) + { + Capability _cap = _f.parse( ResTraits::kind, *it ); + _deps[Dep::RECOMMENDS].insert(_cap); + } + + for (std::list::const_iterator it = selImpl->_requires.begin(); it != selImpl->_requires.end(); it++) + { + Capability _cap = _f.parse( ResTraits::kind, *it ); + _deps[Dep::REQUIRES].insert(_cap); + } + + for (std::list::const_iterator it = selImpl->_conflicts.begin(); it != selImpl->_conflicts.end(); it++) + { + Capability _cap = _f.parse( ResTraits::kind, *it ); + _deps[Dep::CONFLICTS].insert(_cap); + } + + for (std::list::const_iterator it = selImpl->_recommends.begin(); it != selImpl->_pkgrecommends.end(); it++) + { + Capability _cap = _f.parse( ResTraits::kind, *it ); + _deps[Dep::RECOMMENDS].insert(_cap); + } + + for (std::list::const_iterator it = selImpl->_requires.begin(); it != selImpl->_pkgrequires.end(); it++) + { + Capability _cap = _f.parse( ResTraits::kind, *it ); + _deps[Dep::REQUIRES].insert(_cap); + } + + NVRAD nvrad = NVRAD( selImpl->_name, Edition(selImpl->_version, selImpl->_release, std::string()), Arch(selImpl->_arch), _deps ); + result = detail::makeResolvableFromImpl( nvrad, selImpl ); + } + ///////////////////////////////////////////////////////////////// + } // namespace tagfile + /////////////////////////////////////////////////////////////////// + ///////////////////////////////////////////////////////////////// + } // namespace parser + /////////////////////////////////////////////////////////////////// + ///////////////////////////////////////////////////////////////// +} // namespace zypp +/////////////////////////////////////////////////////////////////// diff --git a/zypp/source/susetags/PatternTagFileParser.h b/zypp/source/susetags/PatternTagFileParser.h new file mode 100644 index 0000000..d83043d --- /dev/null +++ b/zypp/source/susetags/PatternTagFileParser.h @@ -0,0 +1,67 @@ +/*---------------------------------------------------------------------\ +| ____ _ __ __ ___ | +| |__ / \ / / . \ . \ | +| / / \ V /| _/ _/ | +| / /__ | | | | | | | +| /_____||_| |_| |_| | +| | +\---------------------------------------------------------------------*/ +/** \file zypp/source/susetags/PatternTagFileParser.h + * +*/ +#ifndef ZYPP_PARSER_TAGFILE_PATTERNTAGFILEPARSER_H +#define ZYPP_PARSER_TAGFILE_PATTERNTAGFILEPARSER_H + +#include +#include +#include +#include + +#include "zypp/parser/tagfile/TagFileParser.h" +#include "zypp/parser/tagfile/ParseException.h" +#include "zypp/Pattern.h" +#include "zypp/source/susetags/SuseTagsPatternImpl.h" + +#include "zypp/Pathname.h" + +/////////////////////////////////////////////////////////////////// +namespace zypp +{ ///////////////////////////////////////////////////////////////// + /////////////////////////////////////////////////////////////////// + namespace source + { ///////////////////////////////////////////////////////////////// + /////////////////////////////////////////////////////////////////// + namespace susetags + { ///////////////////////////////////////////////////////////////// + + /////////////////////////////////////////////////////////////////// + // + // CLASS NAME : PatternTagFileParser + // + /** Tagfile parser. */ + struct PatternTagFileParser : public zypp::parser::tagfile::TagFileParser + { + Pattern::Ptr result; + shared_ptr selImpl; + + PatternTagFileParser(); + virtual ~PatternTagFileParser() + {} + + void consume( const SingleTag &tag ); + void consume( const MultiTag &tag ); + void endParse(); + }; + /////////////////////////////////////////////////////////////////// + Pattern::Ptr parsePattern( const Pathname & file_r ); + ///////////////////////////////////////////////////////////////// + } // namespace source + /////////////////////////////////////////////////////////////////// + ///////////////////////////////////////////////////////////////// + } // namespace susetags + /////////////////////////////////////////////////////////////////// + ///////////////////////////////////////////////////////////////// +} // namespace zypp +/////////////////////////////////////////////////////////////////// +// +#endif // ZYPP_PARSER_TAGFILE_PATTERNTAGFILEPPARSER_H diff --git a/zypp/source/susetags/SelectionSelFileParser.cc b/zypp/source/susetags/SelectionTagFileParser.cc similarity index 92% rename from zypp/source/susetags/SelectionSelFileParser.cc rename to zypp/source/susetags/SelectionTagFileParser.cc index ef98fd2..10a276f 100644 --- a/zypp/source/susetags/SelectionSelFileParser.cc +++ b/zypp/source/susetags/SelectionTagFileParser.cc @@ -6,7 +6,7 @@ | /_____||_| |_| |_| | | | \---------------------------------------------------------------------*/ -/** \file zypp/parser/tagfile/SelectionSelFileParser.cc +/** \file zypp/parser/tagfile/SelectionTagFileParser.cc * */ #include @@ -21,9 +21,10 @@ #include "zypp/base/String.h" #include "zypp/CapFactory.h" -#include "zypp/source/susetags/SelectionSelFileParser.h" +#include "zypp/source/susetags/SelectionTagFileParser.h" #include +#undef ZYPP_BASE_LOGGER_LOGGROUP #define ZYPP_BASE_LOGGER_LOGGROUP "SelectionsTagFileParser" using namespace std; @@ -41,18 +42,18 @@ namespace zypp Selection::Ptr parseSelection( const Pathname & file_r ) { - SelectionSelFileParser p; + SelectionTagFileParser p; p.parse( file_r ); return p.result; } - SelectionSelFileParser::SelectionSelFileParser() + SelectionTagFileParser::SelectionTagFileParser() { selImpl = shared_ptr(new SuseTagsSelectionImpl); } - void SelectionSelFileParser::consume( const SingleTag &tag ) + void SelectionTagFileParser::consume( const SingleTag &tag ) { if ( tag.name == "Sum" ) { @@ -87,7 +88,7 @@ namespace zypp } } - void SelectionSelFileParser::consume( const MultiTag &tag ) + void SelectionTagFileParser::consume( const MultiTag &tag ) { if ( tag.name == "Req" ) { @@ -107,7 +108,7 @@ namespace zypp } } - void SelectionSelFileParser::endParse() + void SelectionTagFileParser::endParse() { #warning FIXME how to insert the specific language packages CapFactory _f; diff --git a/zypp/source/susetags/SelectionSelFileParser.h b/zypp/source/susetags/SelectionTagFileParser.h similarity index 87% rename from zypp/source/susetags/SelectionSelFileParser.h rename to zypp/source/susetags/SelectionTagFileParser.h index fc30002..24668c7 100644 --- a/zypp/source/susetags/SelectionSelFileParser.h +++ b/zypp/source/susetags/SelectionTagFileParser.h @@ -9,8 +9,8 @@ /** \file zypp/parser/tagfile/Parser.h * */ -#ifndef ZYPP_PARSER_TAGFILE_SelectionSelFilePARSER_H -#define ZYPP_PARSER_TAGFILE_SelectionSelFilePARSER_H +#ifndef ZYPP_PARSER_TAGFILE_SELECTIONTAGFILEPARSER_H +#define ZYPP_PARSER_TAGFILE_SELECTIONTAGFILEPARSER_H #include #include @@ -36,16 +36,16 @@ namespace zypp /////////////////////////////////////////////////////////////////// // - // CLASS NAME : SelectionSelFileParser + // CLASS NAME : SelectionTagFileParser // /** Tagfile parser. */ - struct SelectionSelFileParser : public zypp::parser::tagfile::TagFileParser + struct SelectionTagFileParser : public zypp::parser::tagfile::TagFileParser { Selection::Ptr result; shared_ptr selImpl; - SelectionSelFileParser(); - virtual ~SelectionSelFileParser() + SelectionTagFileParser(); + virtual ~SelectionTagFileParser() {} void consume( const SingleTag &tag ); @@ -64,4 +64,4 @@ namespace zypp } // namespace zypp /////////////////////////////////////////////////////////////////// // -#endif // ZYPP_PARSER_TAGFILE_SelectionSelFilePPARSER_H +#endif // ZYPP_PARSER_TAGFILE_SELECTIONTAGFILEPPARSER_H diff --git a/zypp/source/susetags/SelectionsParser.cc b/zypp/source/susetags/SelectionsParser.cc deleted file mode 100644 index 6fca408..0000000 --- a/zypp/source/susetags/SelectionsParser.cc +++ /dev/null @@ -1,136 +0,0 @@ -/*---------------------------------------------------------------------\ -| ____ _ __ __ ___ | -| |__ / \ / / . \ . \ | -| / / \ V /| _/ _/ | -| / /__ | | | | | | | -| /_____||_| |_| |_| | -| | -\---------------------------------------------------------------------*/ -/** \file zypp/source/susetags/SelectionsParser.cc - * -*/ -#include -#include "zypp/base/Logger.h" - -#include "zypp/source/susetags/SelectionsParser.h" -#include "zypp/parser/tagfile/Parser.h" -#include "zypp/Selection.h" -#include "zypp/detail/SelectionImpl.h" -#include "zypp/CapFactory.h" -#include "zypp/CapSet.h" - - -using std::endl; - -/////////////////////////////////////////////////////////////////// -namespace zypp -{ ///////////////////////////////////////////////////////////////// - /////////////////////////////////////////////////////////////////// - namespace source - { ///////////////////////////////////////////////////////////////// - /////////////////////////////////////////////////////////////////// - namespace susetags - { ///////////////////////////////////////////////////////////////// - - using namespace parser::tagfile; - - struct SelectionsParser : public parser::tagfile::Parser - { - std::list result; - - shared_ptr pkgImpl; - NVRAD nvrad; - - bool pkgPending() const - { return pkgImpl; } - - void collectPkg( const shared_ptr & nextPkg_r - = shared_ptr() ) - { - if ( pkgPending() ) - { - result.push_back( detail::makeResolvableFromImpl( nvrad, pkgImpl ) ); - } - pkgImpl = nextPkg_r; - } - - void newPkg() - { - collectPkg( shared_ptr(new detail::SelectionImpl) ); - } - - void collectDeps( const std::list & depstr_r, CapSet & capset ) - { - for ( std::list::const_iterator it = depstr_r.begin(); - it != depstr_r.end(); ++it ) - { - capset.insert( CapFactory().parse( ResTraits::kind, *it ) ); - } - } - - /* Consume SingleTag data. */ - virtual void consume( const STag & stag_r ) - { - if ( stag_r.stag.isPlain( "Pkg" ) ) - { - std::vector words; - str::split( stag_r.value, std::back_inserter(words) ); - - if ( str::split( stag_r.value, std::back_inserter(words) ) != 4 ) - ZYPP_THROW( ParseException( "Pkg" ) ); - - newPkg(); - nvrad = NVRAD( words[0], Edition(words[1],words[2]), Arch(words[3]) ); - } - } - - /* Consume MulitTag data. */ - virtual void consume( const MTag & mtag_r ) - { - if ( ! pkgPending() ) - return; - - if ( mtag_r.stag.isPlain( "Prv" ) ) - { - collectDeps( mtag_r.value, nvrad[Dep::PROVIDES] ); - } - else if ( mtag_r.stag.isPlain( "Prq" ) ) - { - collectDeps( mtag_r.value, nvrad[Dep::PREREQUIRES] ); - } - else if ( mtag_r.stag.isPlain( "Req" ) ) - { - collectDeps( mtag_r.value, nvrad[Dep::REQUIRES] ); - } - else if ( mtag_r.stag.isPlain( "Con" ) ) - { - collectDeps( mtag_r.value, nvrad[Dep::CONFLICTS] ); - } - else if ( mtag_r.stag.isPlain( "Obs" ) ) - { - collectDeps( mtag_r.value, nvrad[Dep::OBSOLETES] ); - } - } - - virtual void parseEnd() - { collectPkg(); } - }; - - //////////////////////////////////////////////////////////////////////////// - - std::list parseSelections( const Pathname & file_r ) - { - SelectionsParser p; - p.parse( file_r ); - return p.result; - } - - ///////////////////////////////////////////////////////////////// - } // namespace susetags - /////////////////////////////////////////////////////////////////// - ///////////////////////////////////////////////////////////////// - } // namespace source - /////////////////////////////////////////////////////////////////// - ///////////////////////////////////////////////////////////////// -} // namespace zypp -/////////////////////////////////////////////////////////////////// diff --git a/zypp/source/susetags/SuseTagsImpl.cc b/zypp/source/susetags/SuseTagsImpl.cc index 2ba6c79..4b2167a 100644 --- a/zypp/source/susetags/SuseTagsImpl.cc +++ b/zypp/source/susetags/SuseTagsImpl.cc @@ -18,7 +18,8 @@ #include "zypp/source/susetags/SuseTagsImpl.h" #include "zypp/source/susetags/PackagesParser.h" -#include "zypp/source/susetags/SelectionSelFileParser.h" +#include "zypp/source/susetags/SelectionTagFileParser.h" +#include "zypp/source/susetags/PatternTagFileParser.h" #include "zypp/SourceFactory.h" @@ -84,7 +85,7 @@ namespace zypp std::ifstream sels (p.asString().c_str()); - while (!sels.eof()) + while (sels && !sels.eof()) { std::string selfile; @@ -95,7 +96,7 @@ namespace zypp DBG << "Going to parse selection " << selfile << endl; Pathname file = provideFile(_path + "suse/setup/descr/" + selfile); - DBG << "Selection file to parse " << file << endl; + MIL << "Selection file to parse " << file << endl; Selection::Ptr sel( parseSelection( file ) ); @@ -106,6 +107,34 @@ namespace zypp DBG << "Parsing of " << file << " done" << endl; } + + // parse patterns + p = provideFile(_path + "suse/setup/descr/patterns"); + + std::ifstream pats (p.asString().c_str()); + + while (pats && !pats.eof()) + { + std::string patfile; + + getline(pats,patfile); + + if (patfile.empty() ) continue; + + DBG << "Going to parse pattern " << patfile << endl; + + Pathname file = provideFile(_path + "suse/setup/descr/" + patfile); + MIL << "Pattern file to parse " << file << endl; + + Pattern::Ptr pat( parsePattern( file ) ); + + DBG << "Pattern:" << pat << endl; + + if (pat) + _store.insert( pat ); + + DBG << "Parsing of " << file << " done" << endl; + } } /////////////////////////////////////////////////////////////////// // diff --git a/zypp/source/susetags/SuseTagsPatternImpl.cc b/zypp/source/susetags/SuseTagsPatternImpl.cc new file mode 100644 index 0000000..c55ec6c --- /dev/null +++ b/zypp/source/susetags/SuseTagsPatternImpl.cc @@ -0,0 +1,62 @@ +/*---------------------------------------------------------------------\ +| ____ _ __ __ ___ | +| |__ / \ / / . \ . \ | +| / / \ V /| _/ _/ | +| / /__ | | | | | | | +| /_____||_| |_| |_| | +| | +\---------------------------------------------------------------------*/ +/** \file zypp/detail/PatternImpl.cc + * +*/ +#include "zypp/source/susetags/SuseTagsPatternImpl.h" + +using namespace std; + +/////////////////////////////////////////////////////////////////// +namespace zypp +{ ///////////////////////////////////////////////////////////////// + /////////////////////////////////////////////////////////////////// + namespace source + { ///////////////////////////////////////////////////////////////// + namespace susetags + { + /////////////////////////////////////////////////////////////////// + // + // METHOD NAME : PatternImpl::PatternImpl + // METHOD TYPE : Ctor + // + SuseTagsPatternImpl::SuseTagsPatternImpl() + {} + + /////////////////////////////////////////////////////////////////// + // + // METHOD NAME : PatternImpl::~PatternImpl + // METHOD TYPE : Dtor + // + SuseTagsPatternImpl::~SuseTagsPatternImpl() + {} + + + TranslatedText SuseTagsPatternImpl::summary() const + { return _summary; } + + TranslatedText SuseTagsPatternImpl::description() const + { return _summary; } + + Label SuseTagsPatternImpl::category() const + { return _category; } + + bool SuseTagsPatternImpl::visible() const + { return _visible; } + + Label SuseTagsPatternImpl::order() const + { return _order; } + + ///////////////////////////////////////////////////////////////// + } // namespace detail + /////////////////////////////////////////////////////////////////// + } + ///////////////////////////////////////////////////////////////// +} // namespace zypp +/////////////////////////////////////////////////////////////////// diff --git a/zypp/source/susetags/SuseTagsPatternImpl.h b/zypp/source/susetags/SuseTagsPatternImpl.h new file mode 100644 index 0000000..137b1b2 --- /dev/null +++ b/zypp/source/susetags/SuseTagsPatternImpl.h @@ -0,0 +1,97 @@ +/*---------------------------------------------------------------------\ +| ____ _ __ __ ___ | +| |__ / \ / / . \ . \ | +| / / \ V /| _/ _/ | +| / /__ | | | | | | | +| /_____||_| |_| |_| | +| | +\---------------------------------------------------------------------*/ +/** \file zypp/detail/PatternImpl.h + * +*/ +#ifndef ZYPP_DETAIL_SUSETAGS_PATTERNIMPL_H +#define ZYPP_DETAIL_SUSETAGS_PATTERNIMPL_H + +#include "zypp/detail/PatternImplIf.h" + +/////////////////////////////////////////////////////////////////// +namespace zypp +{ ///////////////////////////////////////////////////////////////// + /////////////////////////////////////////////////////////////////// + namespace source + { ///////////////////////////////////////////////////////////////// + namespace susetags + { + + /////////////////////////////////////////////////////////////////// + // + // CLASS NAME : PatternImpl + // + /** + */ + struct SuseTagsPatternImpl : public zypp::detail::PatternImplIf + { + public: + SuseTagsPatternImpl(); + virtual ~SuseTagsPatternImpl(); + + /* + virtual std::list suggests() const; + virtual std::list recommends() const; + virtual std::list insnotify( const LangCode & lang = LangCode("") ) const; + virtual std::list delnotify( const LangCode & lang = LangCode("") ) const; + virtual ByteCount size() const; + virtual bool providesSources() const; + virtual std::string instSrcLabel() const; + virtual Vendor instSrcVendor() const; + virtual unsigned instSrcRank() const; + virtual std::list suggests_ptrs() const; + virtual std::list recommends_ptrs() const; + virtual std::list inspacks( const LangCode & lang = LangCode("") ) const; + virtual std::list delpacks( const LangCode & lang = LangCode("") ) const; + virtual PM::LocaleSet supportedLocales() const; + virtual std::set pureInspacks_ptrs( const LangCode & lang ) const; + virtual std::set inspacks_ptrs( const LangCode & lang ) const; + virtual std::set delpacks_ptrs( const LangCode & lang ) const; + virtual bool isBase() const; + virtual PMError provideSelToInstall( Pathname & path_r ) const; + */ + + virtual TranslatedText summary() const; + virtual TranslatedText description() const; + virtual Label category() const; + virtual bool visible() const; + virtual Label order() const; + + TranslatedText _summary; + std::string _parser_version; + std::string _name; + std::string _version; + std::string _release; + std::string _arch; + std::string _order; + std::string _category; + bool _visible; + + std::list _suggests; + std::list _recommends; + std::list _requires; + std::list _conflicts; + std::list _pkgsuggests; + std::list _pkgrecommends; + std::list _pkgrequires; + std::list _supported_locales; + std::map< LanguageCode, std::list > _insnotify; + std::map< LanguageCode, std::list > _delnotify; + + }; + /////////////////////////////////////////////////////////////////// + + ///////////////////////////////////////////////////////////////// + } // namespace susetags + /////////////////////////////////////////////////////////////////// + } // namespace source + ///////////////////////////////////////////////////////////////// +} // namespace zypp +/////////////////////////////////////////////////////////////////// +#endif // ZYPP_DETAIL_PATTERNIMPL_H -- 2.7.4