Interface IElementFactory<TDocument, TElement>
- Namespace
- AngleSharp.Dom
- Assembly
- AngleSharp.dll
Represents an element factory.
public interface IElementFactory<TDocument, TElement> where TDocument : IDocument where TElement : IElement
Type Parameters
TDocument
The type of root document.
TElement
The common type of elements to create.
- Extension Methods
Methods
Create(TDocument, string, string?, NodeFlags)
Creates a new element with the given local name and optional prefix.
TElement Create(TDocument document, string localName, string? prefix = null, NodeFlags flags = NodeFlags.None)
Parameters
document
TDocumentThe owner of the element.
localName
stringThe local name of the element.
prefix
stringThe optional prefix of the element.
flags
NodeFlagsThe optional flags for the node.
Returns
- TElement
The created document's child element.