TriBool.h

Go to the documentation of this file.
00001 /*---------------------------------------------------------------------\
00002 |                          ____ _   __ __ ___                          |
00003 |                         |__  / \ / / . \ . \                         |
00004 |                           / / \ V /|  _/  _/                         |
00005 |                          / /__ | | | | | |                           |
00006 |                         /_____||_| |_| |_|                           |
00007 |                                                                      |
00008 \---------------------------------------------------------------------*/
00012 #ifndef ZYPP_TRIBOOL_H
00013 #define ZYPP_TRIBOOL_H
00014 
00015 #include <iosfwd>
00016 #include <boost/logic/tribool.hpp>
00017 
00019 namespace zypp
00020 { 
00021 
00039   typedef boost::logic::tribool TriBool;
00040   using   boost::logic::tribool;
00041   using   boost::logic::indeterminate;
00042 
00044 } // namespace zypp
00046 namespace boost
00047 {
00048     namespace logic
00049     {
00051       inline std::ostream & operator<<(std::ostream & s, const tribool & obj)
00052       {
00053         if (indeterminate(obj))
00054           s << "indeterminate";
00055         else if (obj)
00056           s << "true";
00057         else
00058           s << "false";
00059         return s;
00060       }
00061     }
00062 }
00063 #endif // ZYPP_TRIBOOL_H

doxygen