Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / XmlUtils / System / Xml / Xsl / XsltOld / newinstructionaction.cs / 1 / newinstructionaction.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml.Xsl.XsltOld { using Res = System.Xml.Utils.Res; using System; using System.Diagnostics; using System.Xml; using System.Xml.XPath; internal class NewInstructionAction : ContainerAction { string name; string parent; bool fallback; internal override void Compile(Compiler compiler) { XPathNavigator nav = compiler.Input.Navigator.Clone(); name = nav.Name; nav.MoveToParent(); parent = nav.Name; if (compiler.Recurse()) { CompileSelectiveTemplate(compiler); compiler.ToParent(); } } internal void CompileSelectiveTemplate(Compiler compiler){ NavigatorInput input = compiler.Input; do{ if (Keywords.Equals(input.NamespaceURI, input.Atoms.XsltNamespace) && Keywords.Equals(input.LocalName, input.Atoms.Fallback)){ fallback = true; if (compiler.Recurse()){ CompileTemplate(compiler); compiler.ToParent(); } } } while (compiler.Advance()); } internal override void Execute(Processor processor, ActionFrame frame) { Debug.Assert(processor != null && frame != null); switch (frame.State) { case Initialized: if (!fallback) { throw XsltException.Create(Res.Xslt_UnknownExtensionElement, this.name); } if (this.containedActions != null && this.containedActions.Count > 0) { processor.PushActionFrame(frame); frame.State = ProcessingChildren; break; } else goto case ProcessingChildren; case ProcessingChildren: frame.Finished(); break; default: Debug.Fail("Invalid Container action execution state"); break; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //----------------------------------------------------------------------------- namespace System.Xml.Xsl.XsltOld { using Res = System.Xml.Utils.Res; using System; using System.Diagnostics; using System.Xml; using System.Xml.XPath; internal class NewInstructionAction : ContainerAction { string name; string parent; bool fallback; internal override void Compile(Compiler compiler) { XPathNavigator nav = compiler.Input.Navigator.Clone(); name = nav.Name; nav.MoveToParent(); parent = nav.Name; if (compiler.Recurse()) { CompileSelectiveTemplate(compiler); compiler.ToParent(); } } internal void CompileSelectiveTemplate(Compiler compiler){ NavigatorInput input = compiler.Input; do{ if (Keywords.Equals(input.NamespaceURI, input.Atoms.XsltNamespace) && Keywords.Equals(input.LocalName, input.Atoms.Fallback)){ fallback = true; if (compiler.Recurse()){ CompileTemplate(compiler); compiler.ToParent(); } } } while (compiler.Advance()); } internal override void Execute(Processor processor, ActionFrame frame) { Debug.Assert(processor != null && frame != null); switch (frame.State) { case Initialized: if (!fallback) { throw XsltException.Create(Res.Xslt_UnknownExtensionElement, this.name); } if (this.containedActions != null && this.containedActions.Count > 0) { processor.PushActionFrame(frame); frame.State = ProcessingChildren; break; } else goto case ProcessingChildren; case ProcessingChildren: frame.Finished(); break; default: Debug.Fail("Invalid Container action execution state"); break; } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- ManualWorkflowSchedulerService.cs
- HttpModule.cs
- HyperlinkAutomationPeer.cs
- SvcMapFileSerializer.cs
- SerializationInfoEnumerator.cs
- FileEnumerator.cs
- StorageEntityTypeMapping.cs
- ContextProperty.cs
- SamlAudienceRestrictionCondition.cs
- RegexGroup.cs
- CheckBox.cs
- CollectionConverter.cs
- COM2Properties.cs
- ListManagerBindingsCollection.cs
- PropertyGridCommands.cs
- ErrorWebPart.cs
- ProfessionalColorTable.cs
- InstalledFontCollection.cs
- SQLRoleProvider.cs
- InvokeAction.cs
- StringDictionary.cs
- XamlPointCollectionSerializer.cs
- PieceNameHelper.cs
- SafeArrayTypeMismatchException.cs
- DBAsyncResult.cs
- OleDbErrorCollection.cs
- SeekStoryboard.cs
- ContactManager.cs
- TearOffProxy.cs
- BitmapImage.cs
- MemberAccessException.cs
- FileDataSourceCache.cs
- _CommandStream.cs
- CreateUserErrorEventArgs.cs
- ObjectParameter.cs
- PageContent.cs
- BasicKeyConstraint.cs
- FaultException.cs
- LocalizationParserHooks.cs
- WebPartActionVerb.cs
- CodeDOMProvider.cs
- ByteFacetDescriptionElement.cs
- SimpleTypeResolver.cs
- FillErrorEventArgs.cs
- ButtonFlatAdapter.cs
- TagPrefixAttribute.cs
- FormsIdentity.cs
- ConfigurationManagerInternal.cs
- XmlWrappingWriter.cs
- LogWriteRestartAreaAsyncResult.cs
- LinkConverter.cs
- ContentType.cs
- MediaElement.cs
- ImageDrawing.cs
- SessionStateUtil.cs
- MachineKeyConverter.cs
- CodePageEncoding.cs
- TextSelectionHighlightLayer.cs
- GridViewDeletedEventArgs.cs
- GeometryValueSerializer.cs
- EntityDataReader.cs
- AssociationType.cs
- ByteArrayHelperWithString.cs
- PageBuildProvider.cs
- VisualProxy.cs
- WinEventHandler.cs
- BrowserCapabilitiesCompiler.cs
- SqlUtils.cs
- SrgsRuleRef.cs
- HiddenFieldPageStatePersister.cs
- TableItemStyle.cs
- CodeGeneratorOptions.cs
- ActivitiesCollection.cs
- BooleanStorage.cs
- documentation.cs
- Codec.cs
- XmlParserContext.cs
- Buffer.cs
- CapabilitiesAssignment.cs
- GradientStopCollection.cs
- VirtualPathUtility.cs
- Helper.cs
- ExclusiveCanonicalizationTransform.cs
- ToolStripManager.cs
- TraceSwitch.cs
- ClientType.cs
- PageThemeCodeDomTreeGenerator.cs
- PopupRoot.cs
- CodeConditionStatement.cs
- BitmapInitialize.cs
- SelectionRangeConverter.cs
- ConstraintCollection.cs
- HorizontalAlignConverter.cs
- HtmlEmptyTagControlBuilder.cs
- SBCSCodePageEncoding.cs
- AddInStore.cs
- HtmlTableRowCollection.cs
- ExternalException.cs
- CalendarAutoFormat.cs
- Utils.cs