- added devel configure switch zo disable building zmd (in case you
[platform/upstream/libzypp.git] / zypp / NVRA.cc
1 /*---------------------------------------------------------------------\
2 |                          ____ _   __ __ ___                          |
3 |                         |__  / \ / / . \ . \                         |
4 |                           / / \ V /|  _/  _/                         |
5 |                          / /__ | | | | | |                           |
6 |                         /_____||_| |_| |_|                           |
7 |                                                                      |
8 \---------------------------------------------------------------------*/
9 /** \file       zypp/NVRA.cc
10  *
11 */
12 #include <iostream>
13
14 #include "zypp/NVRA.h"
15 #include "zypp/Resolvable.h"
16
17 using std::endl;
18
19 ///////////////////////////////////////////////////////////////////
20 namespace zypp
21 { /////////////////////////////////////////////////////////////////
22
23   NVRA::NVRA( Resolvable::constPtr res_r );
24   {
25     if ( res_r )
26       {
27         *this = NVRA( res_r->name(), res_r->edition(), res_r->arch() );
28       }
29   }
30
31   /******************************************************************
32   **
33   **    FUNCTION NAME : operator<<
34   **    FUNCTION TYPE : std::ostream &
35   */
36   std::ostream & operator<<( std::ostream & str, const NVRA & obj )
37   {
38     return str << obj.name << '-' << obj.edition << '.' << obj.arch;
39   }
40
41   /////////////////////////////////////////////////////////////////
42 } // namespace zypp
43 ///////////////////////////////////////////////////////////////////