libzypp  16.22.5
ResolverProblem.h
Go to the documentation of this file.
1 /*
2  *
3  * Easy-to use interface to the ZYPP dependency resolver
4  *
5  * Author: Stefan Hundhammer <sh@suse.de>
6  *
7  **/
8 
9 #ifndef ZYPP_RESOLVERPROBLEM_H
10 #define ZYPP_RESOLVERPROBLEM_H
11 
12 #include <list>
13 #include <string>
14 
15 #include "zypp/ProblemTypes.h"
16 #include "zypp/ProblemSolution.h"
17 
19 namespace zypp
20 {
26  {
27  public:
31  ResolverProblem( std::string description );
33  ResolverProblem( std::string description, std::string details );
34 
37 
38 
42  const std::string & description() const;
43 
48  const std::string & details() const;
49 
64  const ProblemSolutionList & solutions() const;
65 
66 
70  void setDescription( std::string description );
71 
75  void setDetails( std::string details );
76 
81  void addSolution( ProblemSolution_Ptr solution, bool inFront = false );
82 
83  private:
84  class Impl;
86  };
87 
89  std::ostream & operator<<( std::ostream &, const ResolverProblem & obj );
90 
92  std::ostream & operator<<( std::ostream &, const ResolverProblemList & obj );
93 
94 
95 } // namespace zypp
97 #endif // ZYPP_RESOLVERPROBLEM_H
98 
std::list< ProblemSolution_Ptr > ProblemSolutionList
Definition: ProblemTypes.h:43
void addSolution(ProblemSolution_Ptr solution, bool inFront=false)
Add a solution to this problem.
~ResolverProblem()
Destructor.
const std::string & description() const
Return a one-line description of the problem.
ResolverProblem implementation.
std::list< ResolverProblem_Ptr > ResolverProblemList
Definition: ProblemTypes.h:46
std::ostream & operator<<(std::ostream &str, const Exception &obj)
Definition: Exception.cc:147
void setDetails(std::string details)
Set detail description of the problem.
const std::string & details() const
Return a (possibly muti-line) detailed description of the problem or an empty string if there are no ...
Base class for reference counted objects.
RWCOW_pointer< Impl > _pimpl
Describe a solver problem and offer solutions.
ResolverProblem()
Constructor.
const ProblemSolutionList & solutions() const
Return the possible solutions to this problem.
void setDescription(std::string description)
Set description of the problem.