internal Element(Document document, IElement root, TParent parrent, IHtmlSerializerFactory serializerFactory) : base(document, root, parrent, serializerFactory) { attributeSet = new TTag(); name = attributeSet.TagName; Parent = (TParent)base.Parent; }
public void SetUp() { var settings = new HtmlSerializerSettings(); settings.AddAttributeValueTypeSerializer(new HtmlAttributeBoolTypePrinter()); settings.AddAttributeSerializer(new HtmlAttributeUpCaseClassAttribute()); serializerFactory = new HtmlSerializerFactory(settings); elementFactory = new ElementFactory(); }
public IElement <TAttributesSet, IElement> Create <TAttributesSet>( Expression <Func <ITagSet <IElement>, IElement <TAttributesSet, IElement> > > tagSelector, IHtmlSerializerFactory serializerFactory) where TAttributesSet : IGlobalElement, new() { Element <TAttributesSet, IElement> element = null; element = new Element <TAttributesSet, IElement>(null, element, null, serializerFactory); return(element); }
public Document(IHtmlSerializerFactory serializerFactory, string typeValue) { this.serializerFactory = serializerFactory; TypeValue = typeValue; var html = default(Element <Html, IElement>); html = new Element <Html, IElement>(this, html, null, serializerFactory); Html = html; Head = html.AddChild(x => x.Head); Body = html.AddChild(x => x.Body); }
public Document(IHtmlSerializerFactory serializerFactory, DocumentType documentType = DocumentType.Html5) { this.serializerFactory = serializerFactory; TypeValue = documentType.GetDescription(); var html = default(Element <Html, IElement>); html = new Element <Html, IElement>(this, html, null, serializerFactory); Html = html; Head = html.AddChild(x => x.Head); Body = html.AddChild(x => x.Body); }
public void SetUp() { serializerFactory = new HtmlSerializerFactory(); elementFactory = new ElementFactory(); }
private Element(Document document, IElement root, TParent parrent, TTag attributeSet, IHtmlSerializerFactory serializerFactory) : base(document, root, parrent, serializerFactory) { name = attributeSet.TagName; Parent = (TParent)base.Parent; }