Legend

Class
Struct
Enum
Interface
Delegate
Constructor
Method
Property
Event
Field

Class: RT.Xml.Tag

Summary

Represents an XML tag (element).

Constructors

Tag(string name, IEnumerable<Attribute> attributes, params Node[] contents)
Represents an XML tag (element).

Instance methods

void
Add(Attribute attribute)
Adds an attribute. Throws an exception if an attribute by this name already exists.
void
Add(Node node)
Appends the specified node (which could be a Text or a Tag) to the end of this tag’s children.
void
Add(string name, string value)
Adds an attribute. Throws an exception if an attribute by this name already exists.
void
AddRange(IEnumerable<Node> nodes)
Appends the specified nodes to the end of this tag’s children.
void
AddRange(IEnumerable<Attribute> attributes)
Adds the specified attributes to this tag. If an attribute with the same name already exists, an exception occurs.
void
Remove(Node node)
Removes the specified node from this tag’s children.
void
RemoveAll(Predicate<Node> predicate)
Removes nodes that satisfy the given predicate from this tag’s children.
bool
RemoveAttribute(string name)
Removes an attribute, if present, and returns a value indicating whether an attribute was removed.
void
Set(Attribute attribute)
Adds or replaces an attribute.
void
Set(string name, string value)
void
SetRange(IEnumerable<Attribute> attributes)
Adds or replaces the specified attributes on this tag.
string
  • Overrides: object.ToString()
Refer to the documentation for object.ToString.

Operators

NodeImplicit conversion from String to Text.

Instance properties

TagRefer to the documentation for Node.AsTag.
TagCollectionRefer to the documentation for Node.AsTags.
IEnumerable<Attribute>Enumerates the attributes on this tag.
IEnumerable<Node>Returns this tag’s child nodes, including Text nodes.
TagCollectionReturns this tag’s child tags. (Text nodes are ignored.)
IContent
this[string selector]
Refer to the documentation for Node.this[].
stringReturns the name of this tag.
stringRefer to the documentation for Node.Value.