Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / XmlUtils / System / Xml / Xsl / XsltOld / BeginEvent.cs / 1305376 / BeginEvent.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 BeginEvent : Event { private XPathNodeType nodeType; private string namespaceUri; private string name; private string prefix; private bool empty; private object htmlProps; #if DEBUG private bool replaceNSAliasesDone; #endif public BeginEvent(Compiler compiler) { NavigatorInput input = compiler.Input; Debug.Assert(input != null); Debug.Assert(input.NodeType != XPathNodeType.Namespace); this.nodeType = input.NodeType; this.namespaceUri = input.NamespaceURI; this.name = input.LocalName; this.prefix = input.Prefix; this.empty = input.IsEmptyTag; if (nodeType == XPathNodeType.Element) { this.htmlProps = HtmlElementProps.GetProps(this.name); } else if (nodeType == XPathNodeType.Attribute) { this.htmlProps = HtmlAttributeProps.GetProps(this.name); } } public override void ReplaceNamespaceAlias(Compiler compiler){ #if DEBUG Debug.Assert(! replaceNSAliasesDone, "Second attempt to replace NS aliases!. This bad."); replaceNSAliasesDone = true; #endif if (this.nodeType == XPathNodeType.Attribute && this.namespaceUri.Length == 0) { return ; // '#default' aren't apply to attributes. } NamespaceInfo ResultURIInfo = compiler.FindNamespaceAlias(this.namespaceUri); if (ResultURIInfo != null) { this.namespaceUri = ResultURIInfo.nameSpace; if (ResultURIInfo.prefix != null) { this.prefix = ResultURIInfo.prefix; } } } public override bool Output(Processor processor, ActionFrame frame) { return processor.BeginEvent(this.nodeType, this.prefix, this.name, this.namespaceUri, this.empty, this.htmlProps, false); } } } // 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
- MarshalByValueComponent.cs
- DbConnectionInternal.cs
- TableLayoutCellPaintEventArgs.cs
- PageContentCollection.cs
- SignatureToken.cs
- SafeNativeMethods.cs
- DataObjectCopyingEventArgs.cs
- WebPartUserCapability.cs
- Gdiplus.cs
- While.cs
- OrderedParallelQuery.cs
- InfoCardCryptoHelper.cs
- CheckBoxBaseAdapter.cs
- ScrollItemProviderWrapper.cs
- HttpListenerContext.cs
- CompositeActivityValidator.cs
- TheQuery.cs
- ListBox.cs
- IndexedString.cs
- RewritingPass.cs
- CodeTypeParameter.cs
- PrimarySelectionGlyph.cs
- SqlWebEventProvider.cs
- OleStrCAMarshaler.cs
- XmlUtil.cs
- StringArrayConverter.cs
- RubberbandSelector.cs
- DataGridrowEditEndingEventArgs.cs
- InstanceData.cs
- DispatcherFrame.cs
- PassportAuthenticationEventArgs.cs
- ObjectDataSource.cs
- DetailsViewPagerRow.cs
- InheritanceAttribute.cs
- MailBnfHelper.cs
- TdsParser.cs
- DocumentCollection.cs
- ToolStripPanel.cs
- XmlParserContext.cs
- GridViewItemAutomationPeer.cs
- GridViewActionList.cs
- SortedSet.cs
- SchemaAttDef.cs
- DataServiceQueryOfT.cs
- FontConverter.cs
- AddressAlreadyInUseException.cs
- BitmapMetadataEnumerator.cs
- ObjectStateEntryDbUpdatableDataRecord.cs
- ReaderContextStackData.cs
- Win32SafeHandles.cs
- InternalTypeHelper.cs
- RegistrySecurity.cs
- COM2ComponentEditor.cs
- ComPlusInstanceProvider.cs
- InvokeGenerator.cs
- CommandBindingCollection.cs
- DefaultValueAttribute.cs
- FixedSOMTable.cs
- TextLine.cs
- InputEventArgs.cs
- HierarchicalDataBoundControl.cs
- SqlSelectStatement.cs
- AssemblyCollection.cs
- RelatedCurrencyManager.cs
- NativeCppClassAttribute.cs
- TextTreeExtractElementUndoUnit.cs
- InputGestureCollection.cs
- PerformanceCounter.cs
- PersonalizationStateInfoCollection.cs
- SqlClientMetaDataCollectionNames.cs
- ZipIOCentralDirectoryBlock.cs
- DataTransferEventArgs.cs
- ReflectionTypeLoadException.cs
- RouteParametersHelper.cs
- UnionExpr.cs
- OrderedDictionaryStateHelper.cs
- InheritablePropertyChangeInfo.cs
- Configuration.cs
- RectangleGeometry.cs
- EUCJPEncoding.cs
- MailMessageEventArgs.cs
- ByteRangeDownloader.cs
- ExpressionBuilderCollection.cs
- CssClassPropertyAttribute.cs
- WebBodyFormatMessageProperty.cs
- SmtpMail.cs
- StatusBarPanelClickEvent.cs
- CompareValidator.cs
- MultipartIdentifier.cs
- TypeLibConverter.cs
- CmsInterop.cs
- WindowsServiceCredential.cs
- DefaultShape.cs
- ExceptionHandlerDesigner.cs
- SqlAggregateChecker.cs
- QilNode.cs
- SqlNodeAnnotations.cs
- TrackBarRenderer.cs
- UIInitializationException.cs
- ConsoleCancelEventArgs.cs