paludis  Version 2.2.0
dep_parser.hh
1 /* vim: set sw=4 sts=4 et foldmethod=syntax : */
2 
3 /*
4  * Copyright (c) 2008, 2011 Ciaran McCreesh
5  *
6  * This file is part of the Paludis package manager. Paludis is free software;
7  * you can redistribute it and/or modify it under the terms of the GNU General
8  * Public License version 2, as published by the Free Software Foundation.
9  *
10  * Paludis is distributed in the hope that it will be useful, but WITHOUT ANY
11  * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
12  * FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
13  * details.
14  *
15  * You should have received a copy of the GNU General Public License along with
16  * this program; if not, write to the Free Software Foundation, Inc., 59 Temple
17  * Place, Suite 330, Boston, MA 02111-1307 USA
18  */
19 
20 #ifndef PALUDIS_GUARD_PALUDIS_REPOSITORIES_FAKE_DEP_PARSER_HH
21 #define PALUDIS_GUARD_PALUDIS_REPOSITORIES_FAKE_DEP_PARSER_HH 1
22 
24 #include <paludis/spec_tree.hh>
27 #include <string>
28 #include <functional>
29 
30 namespace paludis
31 {
32  namespace fakerepository
33  {
35  public Exception
36  {
37  public:
38  /**
39  * Constructor.
40  */
41  FakeDepParseError(const std::string & dep_string,
42  const std::string & message) throw ();
43  };
44 
45  /**
46  * Parse a dependency heirarchy.
47  */
48  std::shared_ptr<DependencySpecTree> parse_depend(const std::string & s,
49  const Environment * const) PALUDIS_VISIBLE;
50 
51  /**
52  * Parse a fetchable uri heirarchy.
53  */
54  std::shared_ptr<FetchableURISpecTree> parse_fetchable_uri(const std::string & s,
55  const Environment * const) PALUDIS_VISIBLE;
56 
57  /**
58  * Parse a simple uri heirarchy.
59  */
60  std::shared_ptr<SimpleURISpecTree> parse_simple_uri(const std::string & s,
61  const Environment * const) PALUDIS_VISIBLE;
62 
63  /**
64  * Parse a license heirarchy.
65  */
66  std::shared_ptr<LicenseSpecTree> parse_license(const std::string & s,
67  const Environment * const) PALUDIS_VISIBLE;
68  }
69 }
70 
71 #endif
Definition: spec_tree-fwd.hh:71
Definition: about_metadata-fwd.hh:23
STL namespace.
Definition: dep_parser.hh:34
Definition: exception.hh:74
Definition: environment.hh:200
#define PALUDIS_VISIBLE
Definition: attributes.hh:71