Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / wpf / src / Core / CSharp / System / Windows / Markup / XamlSerializerUtil.cs / 1305600 / XamlSerializerUtil.cs
//---------------------------------------------------------------------------- // // File: XamlSerializerUtil.cs // // Description: // Static Helper methods used for Serialization. // // Copyright (C) 2005 by Microsoft Corporation. All rights reserved. // //--------------------------------------------------------------------------- using System; using MS.Internal.PresentationCore; namespace System.Windows.Markup { ////// Static helper methods used for Serialization process /// internal static class XamlCoreSerializerUtil { static XamlCoreSerializerUtil() { // // Dummy code to keep IAddChildInternal from being optimized out of // PresentationCore. PLEASE REMOVE WHEN IAddChildInternal DISAPPEARS. // ThrowIfIAddChildInternal("not IAddChildInternal"); } internal static void ThrowIfIAddChildInternal(object o) { // // Dummy code to keep IAddChildInternal from being optimized out of // PresentationCore. PLEASE REMOVE WHEN IAddChildInternal DISAPPEARS. // if ( o is IAddChildInternal) { throw new InvalidOperationException(); } } ////// Throw an exception if the passed string is not empty and is not /// all whitespace. This is used to check IAddChild.AddText calls for /// objects that don't handle text, but may get some whitespace if /// if xml:space="preserve" is set in xaml. /// internal static void ThrowIfNonWhiteSpaceInAddText(string s) { if (s != null) { for (int i = 0; i < s.Length; i++) { if (!Char.IsWhiteSpace(s[i])) { throw new ArgumentException(SR.Get(SRID.NonWhiteSpaceInAddText, s)); } } } } } } // 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
- SamlConstants.cs
- TriggerActionCollection.cs
- NameHandler.cs
- HtmlInputReset.cs
- XmlSchemaAttribute.cs
- ItemsPanelTemplate.cs
- DataServiceEntityAttribute.cs
- ChooseAction.cs
- DataGridViewTopLeftHeaderCell.cs
- ComboBox.cs
- ImageField.cs
- DynamicResourceExtension.cs
- SurrogateEncoder.cs
- IndexedGlyphRun.cs
- Empty.cs
- TabControlEvent.cs
- UnlockInstanceAsyncResult.cs
- ToolBarButton.cs
- WebPartManagerInternals.cs
- Pkcs7Signer.cs
- SQLInt32Storage.cs
- URLBuilder.cs
- UncommonField.cs
- MethodBuilderInstantiation.cs
- ProviderBase.cs
- ProfileModule.cs
- VisualBrush.cs
- KeyEvent.cs
- SessionEndedEventArgs.cs
- InvalidEnumArgumentException.cs
- ExpressionEditorSheet.cs
- WebPartVerbsEventArgs.cs
- Pkcs9Attribute.cs
- UdpDiscoveryEndpointProvider.cs
- DbExpressionRules.cs
- PersonalizationEntry.cs
- Accessors.cs
- ProcessHostServerConfig.cs
- DataBinding.cs
- SqlConnectionFactory.cs
- ToolStripItemRenderEventArgs.cs
- DesignerProperties.cs
- validationstate.cs
- SystemFonts.cs
- TreeChangeInfo.cs
- MouseGestureValueSerializer.cs
- PermissionToken.cs
- ControlParameter.cs
- Pkcs7Signer.cs
- TypeDependencyAttribute.cs
- DataAdapter.cs
- TableCellCollection.cs
- SafeRightsManagementSessionHandle.cs
- RealProxy.cs
- Misc.cs
- validationstate.cs
- ProtocolInformationReader.cs
- StructuredProperty.cs
- ScriptingScriptResourceHandlerSection.cs
- SystemFonts.cs
- ChannelPool.cs
- figurelength.cs
- TrackingRecordPreFilter.cs
- TreeViewDesigner.cs
- SecurityHeaderLayout.cs
- RequiredFieldValidator.cs
- UriScheme.cs
- TextTreeRootTextBlock.cs
- EdmFunctions.cs
- ExpressionBuilder.cs
- OracleCommandBuilder.cs
- Type.cs
- EndEvent.cs
- LinkedResourceCollection.cs
- Attribute.cs
- Positioning.cs
- wgx_commands.cs
- StringFreezingAttribute.cs
- TextElementCollection.cs
- CfgParser.cs
- Quaternion.cs
- AsyncDataRequest.cs
- VectorKeyFrameCollection.cs
- CodePageUtils.cs
- ButtonRenderer.cs
- StringUtil.cs
- RenderData.cs
- DateRangeEvent.cs
- ConcurrentQueue.cs
- FontResourceCache.cs
- _SslState.cs
- InstanceData.cs
- DataGridDefaultColumnWidthTypeConverter.cs
- ModelTypeConverter.cs
- UInt16.cs
- Stacktrace.cs
- XmlDataSource.cs
- ProfessionalColorTable.cs
- ServicesUtilities.cs
- CodePageUtils.cs