Code:
/ Net / Net / 3.5.50727.3053 / DEVDIV / depot / DevDiv / releases / Orcas / SP / wpf / src / Framework / System / Windows / Markup / ParserHooks.cs / 1 / ParserHooks.cs
/****************************************************************************\
*
* File: ParserHooks.cs
*
* Purpose: Callback at parse time for node processing
*
* Copyright (C) by Microsoft Corporation. All rights reserved.
*
\***************************************************************************/
using System.ComponentModel;
using System.ComponentModel.Design.Serialization;
using System.Reflection;
using System;
using System.Xml;
#if PBTCOMPILER
namespace MS.Internal.Markup
#else
namespace System.Windows.Markup
#endif
{
///
/// Describes the action the parser is to take after it
/// has called back to the ParserHooks
///
internal enum ParserAction
{
///
/// parser should do normal processing
///
Normal,
///
/// Parser should not process this node.
/// If the current node is an Element, skip the current node and all of its children
/// If the current node is an attribute,skip to the next attribute
///
Skip
}
///
/// The base class for the parse time callbacks.
///
///
/// The localization team will use this under two scenarios
/// 1. The Uid generation tool wants to know the different xaml nodes and their positions in a xaml file
/// 2. Used to strip out the localization attributes during compilation to Baml
///
internal abstract class ParserHooks
{
///
/// Called by parser after it determines what node type for
/// the XML Node and has tokenized the xml node content.
///
///
/// Node types are Resources, Code: Element Object, properties, events etc.
/// The return value is a ParserAction value which indicates if the parser
/// should: continue normal processing; skip this node and any children
///
internal virtual ParserAction LoadNode(XamlNode tokenNode)
{
return ParserAction.Normal;
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
/****************************************************************************\
*
* File: ParserHooks.cs
*
* Purpose: Callback at parse time for node processing
*
* Copyright (C) by Microsoft Corporation. All rights reserved.
*
\***************************************************************************/
using System.ComponentModel;
using System.ComponentModel.Design.Serialization;
using System.Reflection;
using System;
using System.Xml;
#if PBTCOMPILER
namespace MS.Internal.Markup
#else
namespace System.Windows.Markup
#endif
{
///
/// Describes the action the parser is to take after it
/// has called back to the ParserHooks
///
internal enum ParserAction
{
///
/// parser should do normal processing
///
Normal,
///
/// Parser should not process this node.
/// If the current node is an Element, skip the current node and all of its children
/// If the current node is an attribute,skip to the next attribute
///
Skip
}
///
/// The base class for the parse time callbacks.
///
///
/// The localization team will use this under two scenarios
/// 1. The Uid generation tool wants to know the different xaml nodes and their positions in a xaml file
/// 2. Used to strip out the localization attributes during compilation to Baml
///
internal abstract class ParserHooks
{
///
/// Called by parser after it determines what node type for
/// the XML Node and has tokenized the xml node content.
///
///
/// Node types are Resources, Code: Element Object, properties, events etc.
/// The return value is a ParserAction value which indicates if the parser
/// should: continue normal processing; skip this node and any children
///
internal virtual ParserAction LoadNode(XamlNode tokenNode)
{
return ParserAction.Normal;
}
}
}
// File provided for Reference Use Only by Microsoft Corporation (c) 2007.
// Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- CodeArrayIndexerExpression.cs
- ThreadAbortException.cs
- SurrogateSelector.cs
- RawStylusActions.cs
- ErrorFormatter.cs
- WindowsSysHeader.cs
- ChannelPool.cs
- TypedTableBase.cs
- HtmlInputControl.cs
- BufferedGraphics.cs
- KeySplineConverter.cs
- QuaternionAnimation.cs
- ContainerAction.cs
- MediaSystem.cs
- RefreshEventArgs.cs
- HttpListenerTimeoutManager.cs
- PhonemeConverter.cs
- ObjectNavigationPropertyMapping.cs
- NullExtension.cs
- UnaryOperationBinder.cs
- TransactionChannelFaultConverter.cs
- SchemaInfo.cs
- InvokeProviderWrapper.cs
- ContextDataSource.cs
- EntityModelBuildProvider.cs
- Span.cs
- MarkedHighlightComponent.cs
- EventDescriptorCollection.cs
- MultiSelector.cs
- CommandConverter.cs
- TypedElement.cs
- XmlLinkedNode.cs
- SystemIcmpV6Statistics.cs
- HttpClientCertificate.cs
- ReliabilityContractAttribute.cs
- ElementProxy.cs
- TableCellAutomationPeer.cs
- Function.cs
- AuthenticationException.cs
- AssertUtility.cs
- DeclarativeCatalogPart.cs
- ZipIOZip64EndOfCentralDirectoryBlock.cs
- ItemContainerGenerator.cs
- ResourcePool.cs
- PageCatalogPart.cs
- ParameterToken.cs
- RemotingSurrogateSelector.cs
- RootBrowserWindowAutomationPeer.cs
- EventDrivenDesigner.cs
- NotImplementedException.cs
- OutputCacheProfileCollection.cs
- WindowsIPAddress.cs
- DesignerVerbCollection.cs
- RuntimeHandles.cs
- UniqueContractNameValidationBehavior.cs
- DynamicPropertyReader.cs
- StateDesignerConnector.cs
- ContentPlaceHolder.cs
- ToolZone.cs
- MaxValueConverter.cs
- ButtonBase.cs
- rsa.cs
- IndexedGlyphRun.cs
- TreeNodeBindingCollection.cs
- IsolatedStoragePermission.cs
- WebPartPersonalization.cs
- ValueTable.cs
- CrossAppDomainChannel.cs
- MeshGeometry3D.cs
- SettingsPropertyValue.cs
- DetailsViewInsertedEventArgs.cs
- GridViewCancelEditEventArgs.cs
- SqlConnectionStringBuilder.cs
- GridViewRowEventArgs.cs
- DefaultMergeHelper.cs
- NavigatingCancelEventArgs.cs
- RegistrySecurity.cs
- Calendar.cs
- XsltFunctions.cs
- CodeRegionDirective.cs
- SQLByte.cs
- _MultipleConnectAsync.cs
- Point3DIndependentAnimationStorage.cs
- Timer.cs
- PersonalizationProvider.cs
- TcpTransportSecurityElement.cs
- SqlDependencyUtils.cs
- FontWeight.cs
- IriParsingElement.cs
- MarkupObject.cs
- LineInfo.cs
- XAMLParseException.cs
- IriParsingElement.cs
- CompilerScope.cs
- FacetDescriptionElement.cs
- Path.cs
- Events.cs
- StaticSiteMapProvider.cs
- XMLSchema.cs
- safesecurityhelperavalon.cs