1 /*---------------------------------------------------------------------\
3 | |__ / \ / / . \ . \ |
8 \---------------------------------------------------------------------*/
13 #include "zypp/base/LogTools.h"
15 #include "zypp/Glob.h"
19 ///////////////////////////////////////////////////////////////////
21 { /////////////////////////////////////////////////////////////////
22 ///////////////////////////////////////////////////////////////////
24 { /////////////////////////////////////////////////////////////////
26 int Glob::add( const std::string & pattern_r, Flags flags_r )
28 static Flags _APPEND( GLOB_APPEND ); // not published
30 flags_r = _defaultFlags;
34 _result.reset( new ::glob_t );
35 return( _lastGlobReturn = ::glob( pattern_r.c_str(), flags_r, NULL, &(*_result) ) );
38 /******************************************************************
40 ** FUNCTION NAME : operator<<
41 ** FUNCTION TYPE : std::ostream &
43 std::ostream & operator<<( std::ostream & str, const Glob & obj )
45 return dumpRange( str << "(" << obj.size() << ")", obj.begin(), obj.end() );
48 /////////////////////////////////////////////////////////////////
49 } // namespace filesystem
50 ///////////////////////////////////////////////////////////////////
51 /////////////////////////////////////////////////////////////////
53 ///////////////////////////////////////////////////////////////////