Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / XmlUtils / System / Xml / Xsl / XsltOld / CopyCodeAction.cs / 1305376 / CopyCodeAction.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; using System.Collections; internal class CopyCodeAction : Action { // Execution states: private const int Outputting = 2; private ArrayList copyEvents; // Copy code action events internal CopyCodeAction() { this.copyEvents = new ArrayList(); } internal void AddEvent(Event copyEvent) { this.copyEvents.Add(copyEvent); } internal void AddEvents(ArrayList copyEvents) { Debug.Assert(copyEvents != null); this.copyEvents.AddRange(copyEvents); } internal override void ReplaceNamespaceAlias(Compiler compiler) { int count = this.copyEvents.Count; for(int i = 0; i< count; i++) { ((Event) this.copyEvents[i]).ReplaceNamespaceAlias(compiler); } } internal override void Execute(Processor processor, ActionFrame frame) { Debug.Assert(processor != null && frame != null); Debug.Assert(this.copyEvents != null && this.copyEvents.Count > 0); switch (frame.State) { case Initialized: frame.Counter = 0; frame.State = Outputting; goto case Outputting; case Outputting: Debug.Assert(frame.State == Outputting); while (processor.CanContinue) { Debug.Assert(frame.Counter < this.copyEvents.Count); Event copyEvent = (Event) this.copyEvents[frame.Counter]; if (copyEvent.Output(processor, frame) == false) { // This event wasn't processed break; } if (frame.IncrementCounter() >= this.copyEvents.Count) { frame.Finished(); break; } } break; default: Debug.Fail("Invalid CopyCodeAction execution state"); break; } } internal override DbgData GetDbgData(ActionFrame frame) { Debug.Assert(frame.Counter < this.copyEvents.Count); return ((Event)this.copyEvents[frame.Counter]).DbgData; } } } // 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
- TransactionChannelListener.cs
- XmlSchemaException.cs
- VisualStyleElement.cs
- HttpCapabilitiesBase.cs
- TemplatePropertyEntry.cs
- XmlNamedNodeMap.cs
- List.cs
- CngKey.cs
- StateMachineTimers.cs
- XmlName.cs
- BamlResourceSerializer.cs
- XmlComplianceUtil.cs
- SourceFileInfo.cs
- HttpStreamMessageEncoderFactory.cs
- SystemInformation.cs
- TreeNodeCollection.cs
- WebPartEditorApplyVerb.cs
- WsatAdminException.cs
- XmlTextReaderImpl.cs
- _DisconnectOverlappedAsyncResult.cs
- SymmetricAlgorithm.cs
- UnsafeNativeMethodsCLR.cs
- GridViewRowCollection.cs
- httpapplicationstate.cs
- MsmqException.cs
- TypedDataSourceCodeGenerator.cs
- DelayedRegex.cs
- ListBoxItem.cs
- ProfileBuildProvider.cs
- CodeStatement.cs
- GridViewSelectEventArgs.cs
- ServicesSection.cs
- ContentPlaceHolder.cs
- ExceptionHandlers.cs
- Font.cs
- DrawingServices.cs
- BitmapEffectDrawingContent.cs
- PageContentCollection.cs
- CompilationLock.cs
- InheritanceAttribute.cs
- xmlfixedPageInfo.cs
- SetUserPreferenceRequest.cs
- Section.cs
- DataGridViewIntLinkedList.cs
- ControlBuilder.cs
- WindowsTab.cs
- JsonDeserializer.cs
- ProviderException.cs
- ProjectionQueryOptionExpression.cs
- TraceSection.cs
- ContractType.cs
- Query.cs
- Baml2006Reader.cs
- ComponentCollection.cs
- CheckBoxPopupAdapter.cs
- DbConnectionPoolGroupProviderInfo.cs
- DataRowComparer.cs
- UnionExpr.cs
- SafeNativeMethods.cs
- HierarchicalDataBoundControl.cs
- SiteMapProvider.cs
- CommentEmitter.cs
- WpfWebRequestHelper.cs
- NetworkInformationPermission.cs
- ContentIterators.cs
- DateTimeValueSerializer.cs
- HotSpot.cs
- CounterSampleCalculator.cs
- HostUtils.cs
- AddInSegmentDirectoryNotFoundException.cs
- WebPartDeleteVerb.cs
- MarkupCompilePass1.cs
- MultitargetingHelpers.cs
- Html32TextWriter.cs
- AutoResetEvent.cs
- KeyNotFoundException.cs
- MulticastDelegate.cs
- EnvelopeVersion.cs
- SQLMembershipProvider.cs
- WebPartEditorApplyVerb.cs
- ReachPageContentCollectionSerializer.cs
- JpegBitmapEncoder.cs
- EntityRecordInfo.cs
- CheckBoxPopupAdapter.cs
- PersistChildrenAttribute.cs
- UnorderedHashRepartitionStream.cs
- ScriptModule.cs
- EditorZoneAutoFormat.cs
- NavigationService.cs
- XmlILModule.cs
- DataContractSerializerMessageContractImporter.cs
- FrameworkPropertyMetadata.cs
- BidPrivateBase.cs
- XhtmlConformanceSection.cs
- ObjectDataSourceView.cs
- XPathSelfQuery.cs
- ColorTransformHelper.cs
- InstallerTypeAttribute.cs
- ObjectStateManagerMetadata.cs
- DependencyPropertyHelper.cs