HTMLDoctype.h
Go to the documentation of this file.
1/* -*-mode:c++; c-file-style: "gnu";-*- */
2/*
3 * $Id: HTMLDoctype.h,v 1.10 2014/12/07 14:33:02 sebdiaz Exp $
4 *
5 * Copyright (C) 1996 - 2004 Stephen F. Booth <sbooth@gnu.org>
6 * 2007 Sebastien DIAZ <sebastien.diaz@gmail.com>
7 * Part of the GNU cgicc library, http://www.gnu.org/software/cgicc
8 *
9 * This library is free software; you can redistribute it and/or
10 * modify it under the terms of the GNU Lesser General Public
11 * License as published by the Free Software Foundation; either
12 * version 3 of the License, or (at your option) any later version.
13 *
14 * This library is distributed in the hope that it will be useful,
15 * but WITHOUT ANY WARRANTY; without even the implied warranty of
16 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
17 * Lesser General Public License for more details.
18 *
19 * You should have received a copy of the GNU Lesser General Public
20 * License along with this library; if not, write to the Free Software
21 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
22 */
23
24#ifndef _HTMLDOCTYPE_H_
25#define _HTMLDOCTYPE_H_ 1
26
27#ifdef __GNUG__
28# pragma interface
29#endif
30
36#include <string>
37
38#include "MStreamable.h"
39
40 namespace cgicc {
41
42 // ============================================================
43 // Class HTMLDoctype
44 // ============================================================
45
56 class CGICC_API HTMLDoctype : public MStreamable
57 {
58 public:
59
61 enum EDocumentType {
63 eStrict,
65 eTransitional,
67 eFrames,
69 eHTML5
70 };
71
72
77 HTMLDoctype(EDocumentType type = eStrict);
78
83 virtual ~HTMLDoctype();
84
85 virtual void
86 render(std::ostream& out) const;
87
88 private:
89 EDocumentType fType;
90 };
91
92} // namespace cgicc
93
94#endif /* ! _HTMLDOCTYPE_H_ */
95
MStreamable.h
Abstract base class for all streamable objects.
cgicc::HTMLDoctype
Specifies the DTD of the HTML 4 document.
Definition: HTMLDoctype.h:57
cgicc::HTMLDoctype::EDocumentType
EDocumentType
Definition: HTMLDoctype.h:61
cgicc::HTMLDoctype::eFrames
@ eFrames
Definition: HTMLDoctype.h:67
cgicc::HTMLDoctype::eTransitional
@ eTransitional
Definition: HTMLDoctype.h:65
cgicc::HTMLDoctype::eStrict
@ eStrict
Definition: HTMLDoctype.h:63
cgicc::HTMLDoctype::~HTMLDoctype
virtual ~HTMLDoctype()
Destructor.
cgicc::HTMLDoctype::HTMLDoctype
HTMLDoctype(EDocumentType type=eStrict)
Constructor.
cgicc::HTMLDoctype::render
virtual void render(std::ostream &out) const
Write this object to a stream.
cgicc::MStreamable
Mix-in streamable interface.
Definition: MStreamable.h:67
cgicc
The namespace containing the cgicc library.
Definition: Cgicc.h:52