Click or drag to resize

HtmlWriter Class

Class for saving RDF Graphs to a XHTML Table format with the actual Triples embedded as RDFa.
Inheritance Hierarchy

Namespace:  VDS.RDF.Writing
Assembly:  dotNetRDF (in dotNetRDF.dll) Version:
Syntax
public class HtmlWriter : BaseHtmlWriter, IRdfWriter, 
	INamespaceWriter

The HtmlWriter type exposes the following members.

Constructors
  NameDescription
Public methodHtmlWriter
Initializes a new instance of the HtmlWriter class
Top
Properties
  NameDescription
Public propertyCssClassBlankNode
Gets/Sets the CSS class used for the span tags used to display Blank Node IDs.
(Inherited from BaseHtmlWriter.)
Public propertyCssClassBox
Gets/Sets the CSS class used for div tags used to group chunks of markup into a box.
(Inherited from BaseHtmlWriter.)
Public propertyCssClassDatatype
Gets/Sets the CSS class used for the anchor tags used to display Literal datatypes.
(Inherited from BaseHtmlWriter.)
Public propertyCssClassLangSpec
Gets/Sets the CSS class used for the span tags used to display Literal language specifiers.
(Inherited from BaseHtmlWriter.)
Public propertyCssClassLiteral
Gets/Sets the CSS class used for the span tags used to display Literals.
(Inherited from BaseHtmlWriter.)
Public propertyCssClassUri
Gets/Sets the CSS class used for the anchor tags used to display the URIs of URI Nodes.
(Inherited from BaseHtmlWriter.)
Public propertyDefaultNamespaces
Gets/Sets the Default Namespaces to use for writers.
Public propertyStylesheet
Gets/Sets a path to a Stylesheet which is used to format the Graph output.
(Inherited from BaseHtmlWriter.)
Public propertyUriPrefix
Gets/Sets the Prefix applied to href attributes.
(Inherited from BaseHtmlWriter.)
Top
Methods
  NameDescription
Public methodEquals
Determines whether the specified object is equal to the current object.
(Inherited from Object.)
Protected methodFinalize
Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object.)
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Public methodSave(IGraph, TextWriter)
Saves the Result Set to the given Stream as an XHTML Table with embedded RDFa.
Public methodSave(IGraph, String)
Saves the Graph to the given File as an XHTML Table with embedded RDFa.
Public methodSave(IGraph, TextWriter, Boolean)
Save the Graph to the given Stream as an XHTML Table with embedded RDFa.
Public methodToString
Gets the String representation of the writer which is a description of the syntax it produces.
(Overrides ObjectToString.)
Top
Events
  NameDescription
Public eventWarning
Event which is raised if there is a non-fatal error with the RDF being output
Top
Remarks

Since not all Triples can be embedded into XHTML those Triples will not have RDFa generated for them but all Triples will be shown in a human readable format. Triples that can be serialized are roughly equivalent to anything that can be serialized in Turtle i.e. URI/BNode subject, URI predicates and URI/BNode/Literal object.

If you encode Triples which have values datatyped as XML Literals with this writer then round-trip Graph equality is not guaranteed as the RDFa parser will add appropriate Namespace declarations to elements as required by the specification.

See Also