# a_library.cc

Go to the documentation of this file.

    00001 ///
    00002 /// \file       a_library.cc
    00003 ///             ALX Library class based on CODSection class
    00004 ///
    00005
    00006 /*
    00007     Copyright (C) 2010, Nicolas VIVIEN
    00008     Copyright (C) 2005-2011, Net Direct Inc. (http://www.netdirect.ca/)
    00009
    00010     This program is free software; you can redistribute it and/or modify
    00011     it under the terms of the GNU General Public License as published by
    00012     the Free Software Foundation; either version 2 of the License, or
    00013     (at your option) any later version.
    00014
    00015     This program is distributed in the hope that it will be useful,
    00016     but WITHOUT ANY WARRANTY; without even the implied warranty of
    00017     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
    00018
    00019     See the GNU General Public License in the COPYING file at the
    00020     root directory of this project for more details.
    00021 */
    00022
    00023 #include <iostream>
    00024 #include <fstream>
    00025 #include <sstream>
    00026
    00027 #include "a_library.h"
    00028
    00029
    00030 namespace Barry {
    00031
    00032
    00033 namespace ALX {
    00034
    00035
    00036 Library::Library(void)
    00037         : CODSection()
    00038 {
    00039 }
    00040
    00041
    00042 Library::Library(const xmlpp::SaxParser::AttributeList& attrs)
    00043         : CODSection(attrs)
    00044 {
    00045 }
    00046
    00047
    00048 Library::~Library(void)
    00049 {
    00050 }
    00051
    00052
    00053 void Library::Dump(std::ostream &os) const
    00054 {
    00055         os << "  Library " << name << " - " << version << std::endl;
    00056         os << "    ID          : " << id << std::endl;
    00057         os << "    Description : " << description << std::endl;
    00058         os << "    Vendor      : " << vendor << std::endl;
    00059         os << "    Copyright   : " << copyright << std::endl;
    00060         os << "    Required    : " << (isRequired ? "Yes" : "No") << std::endl;
    00061
    00062         std::vector<std::string>::const_iterator b = codfiles.begin(), e = codfiles.end();
    00063
    00064         os << "    Files       : " << std::endl;
    00065         for (; b != e; b++)
    00066                 os << "        - " << directory << "/" << (*b) << std::endl;
    00067 }
    00068
    00069
    00070 } // namespace ALX
    00071
    00072 } // namespace Barry
    00073