libept
TextFormat.h
Go to the documentation of this file.
1#ifndef EPT_DEBTAGS_COLL_TEXTFORMAT_H
2#define EPT_DEBTAGS_COLL_TEXTFORMAT_H
3
8/*
9 * Copyright (C) 2003--2015 Enrico Zini <enrico@debian.org>
10 *
11 * This library is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU Lesser General Public
13 * License as published by the Free Software Foundation; either
14 * version 2.1 of the License, or (at your option) any later version.
15 *
16 * This library is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 * Lesser General Public License for more details.
20 *
21 * You should have received a copy of the GNU Lesser General Public
22 * License along with this library; if not, write to the Free Software
23 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
24 */
25
26#include <cstdio>
27#include <string>
28
29//#define TRACE_PARSE
30
31namespace ept {
32namespace debtags {
33namespace coll {
34struct Fast;
35
36namespace textformat {
37
50int parseElement(FILE* in, const std::string& pathname, std::string& item);
51
52
53/*
54 * Parse a tagged collection, sending the results to out.
55 *
56 * @param out
57 * An output iterator accepting a std::pair<string, string>
58 */
59void parse(FILE* in, const std::string& pathname, Fast& out);
60
61}
62}
63}
64}
65
66#endif
In-memory collection with both item->tags and tag->items mappings.
Definition: fast.h:39
int parseElement(FILE *in, const std::string &pathname, string &item)
Definition: TextFormat.cc:47
void parse(FILE *in, const std::string &pathname, Fast &out)
Definition: TextFormat.cc:168
String functions.
Definition: apt.cc:40