1 /*---------------------------------------------------------------------\
3 | |__ / \ / / . \ . \ |
8 \---------------------------------------------------------------------*/
13 #include "zypp/base/LogTools.h"
15 #include "zypp/Glob.h"
19 ///////////////////////////////////////////////////////////////////
21 { /////////////////////////////////////////////////////////////////
22 ///////////////////////////////////////////////////////////////////
24 { /////////////////////////////////////////////////////////////////
26 int Glob::add( const char * 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, flags_r, NULL, &(*_result) ) );
42 ::globfree( &(*_result) );
48 /******************************************************************
50 ** FUNCTION NAME : operator<<
51 ** FUNCTION TYPE : std::ostream &
53 std::ostream & operator<<( std::ostream & str, const Glob & obj )
55 return dumpRange( str << "(" << obj.size() << ")", obj.begin(), obj.end() );
58 /////////////////////////////////////////////////////////////////
59 } // namespace filesystem
60 ///////////////////////////////////////////////////////////////////
61 /////////////////////////////////////////////////////////////////
63 ///////////////////////////////////////////////////////////////////