Page Speed Optimization Libraries
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Static Public Attributes | List of all members
net_instaweb::DocType Class Reference

#include "doctype.h"

Public Member Functions

 DocType (const DocType &src)
DocTypeoperator= (const DocType &src)
bool operator== (const DocType &other) const
bool operator!= (const DocType &other) const
bool IsXhtml () const
 Return true iff this is a known XHTML doctype (of some version).
bool IsVersion5 () const
 Return true iff this is an HTML 5 or XHTML 5 doctype.
bool Parse (const StringPiece &directive, const ContentType &content_type)

Static Public Attributes

static const DocType kUnknown
static const DocType kHTML5
static const DocType kHTML4Strict
static const DocType kHTML4Transitional
static const DocType kXHTML5
static const DocType kXHTML11
static const DocType kXHTML10Strict
static const DocType kXHTML10Transitional

Detailed Description

Holds an HTML Doctype declaration, providing a parsing mechanism and queries for properties.

Member Function Documentation

bool net_instaweb::DocType::Parse ( const StringPiece &  directive,
const ContentType content_type 

Given the contents of an HTML directive and the content type of the file it appears in, update this DocType to match that specified by the directive and return true. If the directive is not a doctype directive, return false and don't alter the DocType.

Member Data Documentation

const DocType net_instaweb::DocType::kUnknown
TODO(mdsteele): Add more such methods as necessary.

The documentation for this class was generated from the following file: