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
- SerializationEventsCache.cs
- _TransmitFileOverlappedAsyncResult.cs
- IApplicationTrustManager.cs
- DictionaryBase.cs
- panel.cs
- EntryPointNotFoundException.cs
- HtmlWindow.cs
- DelegateOutArgument.cs
- RepeaterItem.cs
- BindingListCollectionView.cs
- HandlerWithFactory.cs
- CultureInfoConverter.cs
- ServiceModelEnhancedConfigurationElementCollection.cs
- ResXBuildProvider.cs
- glyphs.cs
- Run.cs
- ScriptIgnoreAttribute.cs
- FileNameEditor.cs
- TextRangeSerialization.cs
- translator.cs
- wgx_render.cs
- CodeGeneratorOptions.cs
- WeakEventManager.cs
- ItemDragEvent.cs
- ZipIOModeEnforcingStream.cs
- QilGenerator.cs
- DataGridCellItemAutomationPeer.cs
- Journal.cs
- PersonalizationProvider.cs
- IFormattable.cs
- XPathParser.cs
- BaseUriHelper.cs
- InternalPermissions.cs
- PrinterSettings.cs
- SimpleWorkerRequest.cs
- Decorator.cs
- Lease.cs
- BamlBinaryWriter.cs
- InstanceNameConverter.cs
- Shape.cs
- XmlObjectSerializerWriteContext.cs
- ReflectionTypeLoadException.cs
- Tokenizer.cs
- IQueryable.cs
- RegexParser.cs
- HMAC.cs
- Visual.cs
- XmlAttributes.cs
- ToolTipAutomationPeer.cs
- SqlNodeAnnotations.cs
- CryptoHandle.cs
- DBConnectionString.cs
- ObjRef.cs
- ContentDisposition.cs
- SqlDataSourceQuery.cs
- LabelAutomationPeer.cs
- RegexTree.cs
- PanningMessageFilter.cs
- SetterTriggerConditionValueConverter.cs
- NativeMethods.cs
- TextPointer.cs
- UIElementAutomationPeer.cs
- SelectionItemPattern.cs
- MappingModelBuildProvider.cs
- D3DImage.cs
- FunctionQuery.cs
- ObjectStateManagerMetadata.cs
- InitializationEventAttribute.cs
- OdbcStatementHandle.cs
- WrappedReader.cs
- Positioning.cs
- GroupStyle.cs
- WebPartEditorOkVerb.cs
- TableItemStyle.cs
- BinaryQueryOperator.cs
- ConstructorNeedsTagAttribute.cs
- GetLedgerRequest.cs
- ColorAnimationBase.cs
- MethodResolver.cs
- BindToObject.cs
- SystemResourceHost.cs
- XamlReaderConstants.cs
- ObjectStateManager.cs
- DocumentPageTextView.cs
- SecurityCapabilities.cs
- CollectionBase.cs
- SplitterCancelEvent.cs
- WebPartManager.cs
- TextStore.cs
- ListViewSortEventArgs.cs
- Crypto.cs
- Control.cs
- Profiler.cs
- ExpressionBuilderContext.cs
- HwndHost.cs
- XDeferredAxisSource.cs
- NodeLabelEditEvent.cs
- MemberInfoSerializationHolder.cs
- MetadataHelper.cs
- BrowserDefinition.cs