Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / Orcas / NetFXw7 / 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
- ThreadStaticAttribute.cs
- Signature.cs
- HttpConfigurationContext.cs
- CheckBoxRenderer.cs
- Ref.cs
- XmlDataLoader.cs
- MimeWriter.cs
- WebControl.cs
- Utils.cs
- safex509handles.cs
- DataColumnChangeEvent.cs
- DataControlCommands.cs
- CheckBoxList.cs
- FormsAuthenticationConfiguration.cs
- BasicHttpSecurityMode.cs
- DropDownButton.cs
- OpacityConverter.cs
- KeyBinding.cs
- DBDataPermissionAttribute.cs
- ExpressionValueEditor.cs
- CodeMethodReturnStatement.cs
- LineGeometry.cs
- SmiMetaDataProperty.cs
- ExtractCollection.cs
- SourceSwitch.cs
- LocalizationComments.cs
- storepermission.cs
- ProjectionPathBuilder.cs
- JsonUriDataContract.cs
- InlineObject.cs
- EpmTargetTree.cs
- Table.cs
- UnsafeNativeMethodsMilCoreApi.cs
- ClientTarget.cs
- EqualityComparer.cs
- DisplayInformation.cs
- IssuedTokenClientElement.cs
- InheritanceAttribute.cs
- ListSortDescriptionCollection.cs
- CurrentChangingEventArgs.cs
- PropertyManager.cs
- TypeBuilder.cs
- DragEventArgs.cs
- NamedPipeAppDomainProtocolHandler.cs
- WebServiceEndpoint.cs
- DbDataSourceEnumerator.cs
- ColorConverter.cs
- ClusterSafeNativeMethods.cs
- ClassHandlersStore.cs
- ProgressBarAutomationPeer.cs
- MetabaseServerConfig.cs
- DataSourceControlBuilder.cs
- WebPartHeaderCloseVerb.cs
- ThreadAttributes.cs
- GetCryptoTransformRequest.cs
- WizardForm.cs
- ProgressBarAutomationPeer.cs
- metadatamappinghashervisitor.hashsourcebuilder.cs
- MinMaxParagraphWidth.cs
- ComponentResourceKeyConverter.cs
- Internal.cs
- UrlMapping.cs
- TargetConverter.cs
- WorkflowInstanceSuspendedRecord.cs
- ScriptControlDescriptor.cs
- IssuanceLicense.cs
- RC2CryptoServiceProvider.cs
- _emptywebproxy.cs
- WindowPatternIdentifiers.cs
- entitydatasourceentitysetnameconverter.cs
- DbDataAdapter.cs
- Utility.cs
- ToolStripPanel.cs
- ConfigurationManagerInternalFactory.cs
- VisualStyleRenderer.cs
- BamlTreeUpdater.cs
- XamlPointCollectionSerializer.cs
- GeometryHitTestParameters.cs
- ActivatedMessageQueue.cs
- StatusBarAutomationPeer.cs
- HttpListenerPrefixCollection.cs
- PrintPreviewGraphics.cs
- ArraySortHelper.cs
- Deserializer.cs
- IISUnsafeMethods.cs
- CodeThrowExceptionStatement.cs
- View.cs
- XmlQueryType.cs
- Ref.cs
- LocalizableAttribute.cs
- LinkDescriptor.cs
- TextTreeUndoUnit.cs
- FrameworkTemplate.cs
- DbConnectionInternal.cs
- ObjectConverter.cs
- AmbientLight.cs
- TypeSource.cs
- SqlBulkCopyColumnMapping.cs
- SingleAnimationUsingKeyFrames.cs
- IIS7UserPrincipal.cs