source: trunk/lib/html_utility.h @ 376

Last change on this file since 376 was 376, checked in by Jari Häkkinen, 14 years ago

Trivial change: changing variable name href to url.

  • Property svn:keywords set to Id
File size: 1.9 KB
Line 
1#ifndef _theplu_svndigest_html_utility_
2#define _theplu_svndigest_html_utility_
3
4// $Id: html_utility.h 376 2007-06-20 20:16:37Z jari $
5
6/*
7  Copyright (C) 2006, 2007 Peter Johansson
8
9  This file is part of svndigest, http://lev.thep.lu.se/trac/svndigest
10
11  svndigest is free software; you can redistribute it and/or modify it
12  under the terms of the GNU General Public License as published by
13  the Free Software Foundation; either version 2 of the License, or
14  (at your option) any later version.
15
16  svndigest is distributed in the hope that it will be useful, but
17  WITHOUT ANY WARRANTY; without even the implied warranty of
18  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19  General Public License for more details.
20
21  You should have received a copy of the GNU General Public License
22  along with this program; if not, write to the Free Software
23  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
24  02111-1307, USA.
25*/
26
27#include <fstream>
28#include <iosfwd>
29#include <string>
30#include <vector>
31
32namespace theplu{
33namespace svndigest{
34
35  ///
36  /// @brief create anchor
37  ///
38  /// @param url address to link to
39  /// @param name text visible on page
40  /// @param level '../' is added @a level times before @a href
41  /// @param title title of anchor
42  ///
43  std::string anchor(const std::string& url,
44                     const std::string& name, u_int level=0, 
45                     const std::string& title="");
46
47  ///
48  /// @Brief print html footer of page
49  ///
50  void print_footer(std::ostream&);
51   
52  ///
53  /// @brief print html header of page
54  ///
55  /// \param os stream to print to
56  /// \param name
57  /// \param level
58  /// \param
59  void print_header(std::ostream& os, std::string name, u_int level, 
60                    std::string user, std::string item, std::string path);
61
62
63  ///
64  /// @return if trac-revision is set in config file anchor to trac is
65  /// given otherwise just a string corresponding to passed parameter.
66  ///
67  std::string trac_revision(size_t);
68
69}} // end of namespace svndigest end of namespace theplu
70
71#endif
Note: See TracBrowser for help on using the repository browser.