Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / XmlUtils / System / Xml / Xsl / XsltOld / TextAction.cs / 1305376 / TextAction.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 TextAction : CompiledAction { private bool disableOutputEscaping; private string text; internal override void Compile(Compiler compiler) { CompileAttributes(compiler); CompileContent(compiler); } internal override bool CompileAttribute(Compiler compiler) { string name = compiler.Input.LocalName; string value = compiler.Input.Value; if (Ref.Equal(name, compiler.Atoms.DisableOutputEscaping)) { this.disableOutputEscaping = compiler.GetYesNo(value); } else { return false; } return true; } private void CompileContent(Compiler compiler) { if (compiler.Recurse()) { NavigatorInput input = compiler.Input; this.text = string.Empty; do { switch (input.NodeType) { case XPathNodeType.Text: case XPathNodeType.Whitespace: case XPathNodeType.SignificantWhitespace: this.text += input.Value; break; case XPathNodeType.Comment: case XPathNodeType.ProcessingInstruction: break; default: throw compiler.UnexpectedKeyword(); } } while(compiler.Advance()); compiler.ToParent(); } } internal override void Execute(Processor processor, ActionFrame frame) { Debug.Assert(processor != null && frame != null); switch (frame.State) { case Initialized: if (processor.TextEvent(this.text, disableOutputEscaping)) { frame.Finished(); } break; default: Debug.Fail("Invalid execution state in TextAction"); 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
- PolyQuadraticBezierSegment.cs
- XmlSerializationReader.cs
- ObjectListDataBindEventArgs.cs
- XmlTextReader.cs
- PersonalizationState.cs
- ValidationHelper.cs
- SoapIncludeAttribute.cs
- CompoundFileReference.cs
- HttpServerUtilityWrapper.cs
- MeshGeometry3D.cs
- ImageClickEventArgs.cs
- Win32.cs
- StorageEntityContainerMapping.cs
- FrameworkElement.cs
- CodeGroup.cs
- ISO2022Encoding.cs
- UserControlDesigner.cs
- ServiceContractViewControl.Designer.cs
- DataServiceSaveChangesEventArgs.cs
- UIElementPropertyUndoUnit.cs
- PeerOutputChannel.cs
- Walker.cs
- WizardForm.cs
- CheckBoxField.cs
- SurrogateSelector.cs
- StackOverflowException.cs
- WebControlParameterProxy.cs
- ResourcesGenerator.cs
- MapPathBasedVirtualPathProvider.cs
- StringBuilder.cs
- RowToFieldTransformer.cs
- TagMapCollection.cs
- StrongName.cs
- ReferenceSchema.cs
- panel.cs
- XmlnsCompatibleWithAttribute.cs
- DesignerView.Commands.cs
- VariantWrapper.cs
- XPathNode.cs
- CreateRefExpr.cs
- EntityDataSourceStatementEditor.cs
- PassportAuthentication.cs
- WindowsFormsHost.cs
- FileVersionInfo.cs
- CodeExporter.cs
- SafeArrayTypeMismatchException.cs
- HtmlInputSubmit.cs
- ItemCollection.cs
- FixedPageProcessor.cs
- TypePresenter.xaml.cs
- UrlMapping.cs
- ArraySegment.cs
- HtmlTableRow.cs
- SiteMapDataSource.cs
- Renderer.cs
- SendKeys.cs
- ConnectionStringSettings.cs
- ConstraintConverter.cs
- WindowsTreeView.cs
- EntityKey.cs
- WmlCalendarAdapter.cs
- BypassElement.cs
- Vector3DAnimationBase.cs
- XsltContext.cs
- AnnotationHighlightLayer.cs
- IndividualDeviceConfig.cs
- SiteMapNodeItem.cs
- DigestTraceRecordHelper.cs
- MethodAccessException.cs
- TypeProvider.cs
- GeneralTransform3DGroup.cs
- ChannelDispatcher.cs
- XmlTextReaderImplHelpers.cs
- SecurityPolicySection.cs
- FtpCachePolicyElement.cs
- EventManager.cs
- MessagePropertyFilter.cs
- ImmutablePropertyDescriptorGridEntry.cs
- PerformanceCounterManager.cs
- SimplePropertyEntry.cs
- UnsafeNativeMethods.cs
- TextClipboardData.cs
- CacheDependency.cs
- CallbackValidator.cs
- EventLogPermissionEntryCollection.cs
- AdjustableArrowCap.cs
- IssuedSecurityTokenProvider.cs
- SiteMapPathDesigner.cs
- FormsAuthenticationUserCollection.cs
- ConnectionStringsExpressionBuilder.cs
- OpCodes.cs
- LongAverageAggregationOperator.cs
- WebServiceBindingAttribute.cs
- RelationshipEntry.cs
- CompilationUnit.cs
- ReflectionUtil.cs
- LoginCancelEventArgs.cs
- FixedPage.cs
- IntSecurity.cs
- TerminatorSinks.cs