Click or drag to resize

XmlGenerator Class

Generates XML from Syntactik DOM.
Inheritance Hierarchy

Namespace:  Syntactik.Compiler.Generator
Assembly:  Syntactik (in Syntactik.dll) Version: 0.3.0-beta1
Syntax
C#
public class XmlGenerator : AliasResolvingVisitor

The XmlGenerator type exposes the following members.

Constructors
  NameDescription
Public methodXmlGenerator
This constructor should be used if output depends on the name of the document.
Top
Properties
  NameDescription
Protected propertyAliasContext
Keeps track of nested aliases.
(Inherited from AliasResolvingVisitor.)
Protected propertyContext
Provides access to CompilerContext.
(Inherited from AliasResolvingVisitor.)
Protected propertyCurrentDocument
Property is used to keep track of current visiting Document.
(Inherited from AliasResolvingVisitor.)
Public propertyLocationMap
LocationMap is used to map XML validation errors to Syntactik code.
Protected propertyScopeContext
Keeps track of nested namespace scopes.
(Inherited from AliasResolvingVisitor.)
Top
Methods
  NameDescription
Protected methodAddLocationMapRecord
Adds record about IMappedPair in the LocationMap.
Protected methodEnterChoiceContainer
Tries to resolve a pair as a choice.
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.)
Protected methodGetEncoding
Gets encoding of xml-document from Syntactik comments.
Public methodGetHashCode
Serves as the default hash function.
(Inherited from Object.)
Public methodGetType
Gets the Type of the current instance.
(Inherited from Object.)
Public methodStatic memberIsLegalXmlChar
Whether a given character is allowed by XML 1.0.
Protected methodMemberwiseClone
Creates a shallow copy of the current Object.
(Inherited from Object.)
Protected methodOnPair
Method is wrapping call to Accept method of every node.
(Inherited from SyntactikDepthFirstVisitor.)
Public methodOnValue
Method called when the value of the current pair is resolved.
(Overrides AliasResolvingVisitorOnValue(String, ValueType).)
Protected methodResolveAttributes
Go through all entities and resolve attributes for the current node.
(Inherited from AliasResolvingVisitor.)
Protected methodResolveAttributesInAlias
Resolves attributes in Alias. Elements are ignored.
(Inherited from AliasResolvingVisitor.)
Protected methodResolveAttributesInParameter
Resolves attributes in Parameter. Elements are ignored.
(Inherited from AliasResolvingVisitor.)
Protected methodResolveChoiceValue
Method is called for pair with literal choice assignment =::.
(Overrides AliasResolvingVisitorResolveChoiceValue(Pair, ValueType).)
Protected methodResolveDqsEscape
Resolves escape sequence
(Overrides AliasResolvingVisitorResolveDqsEscape(EscapeMatch, StringBuilder).)
Protected methodResolveDqsEscapeChar
Converts EscapeMatch to Char.
(Inherited from AliasResolvingVisitor.)
Protected methodResolvePairValue
Resolves literal value of the pair.
(Inherited from AliasResolvingVisitor.)
Protected methodResolveValue
Resolves literal value of the Pair.
(Inherited from AliasResolvingVisitor.)
Protected methodResolveValueAlias
Resolves literal value of Alias.
(Inherited from AliasResolvingVisitor.)
Protected methodResolveValueParameter
Resolves value of the value parameter.
(Inherited from AliasResolvingVisitor.)
Public methodToString
Returns a string that represents the current object.
(Inherited from Object.)
Public methodVisit(Alias)
Visit method for Alias.
(Overrides AliasResolvingVisitorVisit(Alias).)
Public methodVisit(AliasDefinition)
Visit method for AliasDefinition.
(Inherited from AliasResolvingVisitor.)
Public methodVisit(Argument)
Visit method for Argument.
(Inherited from SyntactikDepthFirstVisitor.)
Public methodVisit(Attribute)
Visit method for Attribute.
(Overrides SyntactikDepthFirstVisitorVisit(Attribute).)
Public methodVisit(Comment)
Visit method for Comment.
(Overrides SyntactikDepthFirstVisitorVisit(Comment).)
Public methodVisit(CompileUnit)
Visit method for CompileUnit.
(Inherited from SyntactikDepthFirstVisitor.)
Public methodVisit(Document)
Visit method for Document.
(Overrides SyntactikDepthFirstVisitorVisit(Document).)
Public methodVisit(Element)
Visit method for Element.
(Overrides AliasResolvingVisitorVisit(Element).)
Public methodVisit(Module)
Visit method for Module.
(Overrides SyntactikDepthFirstVisitorVisit(Module).)
Public methodVisit(NamespaceDefinition)
Visit method for NamespaceDefinition.
(Inherited from SyntactikDepthFirstVisitor.)
Public methodVisit(Pair)
Asks visitor to visit a pair.
(Inherited from SyntactikDepthFirstVisitor.)
Public methodVisit(Parameter)
Visit method for Parameter.
(Inherited from AliasResolvingVisitor.)
Public methodVisit(Scope)
Visit method for Scope.
(Inherited from AliasResolvingVisitor.)
Public methodVisitT(IEnumerableT)
Asks visitor to visit each pair in collection.
(Inherited from SyntactikDepthFirstVisitor.)
Protected methodWriteStartDocument
Writes start of xml document.
Top
Fields
  NameDescription
Protected field_readerDelegate
Delegate is called to create XmlReader to validate each generated XML document.
Protected fieldChoiceStack
Stack of ChoiceInfo.
Protected fieldCurrentModuleMember
Protected fieldDocumentElementAdded
True if document element is added. Used to identify document element in the visitor.
Protected fieldNamespaceResolver
Provides access to services of NamespaceResolver.
(Inherited from AliasResolvingVisitor.)
Protected fieldWriterDelegate
Delegate is called to create XmlWriter for each Document.
Protected fieldXmlTextWriter
XmlWriter is used to generate XML text.
Top
See Also