本文整理汇总了C#中System.Xml.Xsl.Compiler.CreateUseAttributeSetsAction方法的典型用法代码示例。如果您正苦于以下问题:C# Compiler.CreateUseAttributeSetsAction方法的具体用法?C# Compiler.CreateUseAttributeSetsAction怎么用?C# Compiler.CreateUseAttributeSetsAction使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Xml.Xsl.Compiler
的用法示例。
在下文中一共展示了Compiler.CreateUseAttributeSetsAction方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: CompileAttribute
internal override bool CompileAttribute(Compiler compiler) {
string name = compiler.Input.LocalName;
string value = compiler.Input.Value;
if (Keywords.Equals(name, compiler.Atoms.UseAttributeSets)) {
this.useAttributeSets = value;
AddAction(compiler.CreateUseAttributeSetsAction());
Debug.WriteLine("UseAttributeSets = \"" + this.useAttributeSets + "\"");
}
else {
return false;
}
return true;
}
示例2: CompileAttribute
internal override bool CompileAttribute(Compiler compiler) {
string name = compiler.Input.LocalName;
string value = compiler.Input.Value;
if (Keywords.Equals(name, compiler.Atoms.Name)) {
Debug.Assert(this.name == null);
this.name = compiler.CreateXPathQName(value);
Debug.WriteLine("name attribute found: " + this.name);
}
else if (Keywords.Equals(name, compiler.Atoms.UseAttributeSets)) {
// create a UseAttributeSetsAction
// sets come before xsl:attributes
AddAction(compiler.CreateUseAttributeSetsAction());
}
else {
return false;
}
return true;
}
示例3: CompileAttribute
internal override bool CompileAttribute(Compiler compiler) {
string name = compiler.Input.LocalName;
string value = compiler.Input.Value;
if (Keywords.Equals(name, compiler.Atoms.Name)) {
this.nameAvt = Avt.CompileAvt(compiler, value);
Debug.WriteLine("name = \"" + value + "\"");
}
else if (Keywords.Equals(name, compiler.Atoms.Namespace)) {
this.nsAvt = Avt.CompileAvt(compiler, value);
Debug.WriteLine("namespace = \"" + value + "\"");
}
else if (Keywords.Equals(name, compiler.Atoms.UseAttributeSets)) {
AddAction(compiler.CreateUseAttributeSetsAction());
}
else {
return false;
}
return true;
}
示例4: CompileLiteralAttributesAndNamespaces
void CompileLiteralAttributesAndNamespaces(Compiler compiler) {
NavigatorInput input = compiler.Input;
if (input.Navigator.MoveToAttribute(Keywords.s_UseAttributeSets, input.Atoms.XsltNamespace)) {
AddAction(compiler.CreateUseAttributeSetsAction());
input.Navigator.MoveToParent();
}
compiler.InsertExcludedNamespace();
if (input.MoveToFirstAttribute()) {
do {
// Skip everything from Xslt namespace
if (Keywords.Equals(input.NamespaceURI, input.Atoms.XsltNamespace)) {
continue;
}
// Add attribute events
this.AddEvent (compiler.CreateBeginEvent());
this.AddEvents(compiler.CompileAvt(input.Value));
this.AddEvent (new EndEvent(XPathNodeType.Attribute));
}
while (input.MoveToNextAttribute());
input.ToParent();
}
if (input.MoveToFirstNamespace()) {
do {
string uri = input.Value;
if (Keywords.Compare(uri, input.Atoms.XsltNamespace)) {
continue;
}
if (
compiler.IsExcludedNamespace(uri) ||
compiler.IsExtensionNamespace(uri) ||
compiler.IsNamespaceAlias(uri)
) {
continue;
}
this.AddEvent(new NamespaceEvent(input));
}
while (input.MoveToNextNamespace());
input.ToParent();
}
}