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
- TimeSpanMinutesConverter.cs
- GeneralTransform2DTo3D.cs
- _ProxyRegBlob.cs
- FrameworkElementFactory.cs
- AdRotator.cs
- GeneralTransform3D.cs
- EdmTypeAttribute.cs
- UIElement3D.cs
- OrderPreservingMergeHelper.cs
- NotSupportedException.cs
- GetIndexBinder.cs
- HtmlUtf8RawTextWriter.cs
- Sentence.cs
- SymmetricCryptoHandle.cs
- Imaging.cs
- BufferedReadStream.cs
- ParameterCollection.cs
- FileRegion.cs
- OleStrCAMarshaler.cs
- SmiRequestExecutor.cs
- FieldCollectionEditor.cs
- BamlLocalizer.cs
- CommonDialog.cs
- TabItemAutomationPeer.cs
- LabelAutomationPeer.cs
- HttpServerUtilityWrapper.cs
- PropertyChangeTracker.cs
- ResourceLoader.cs
- LinkDescriptor.cs
- DefaultTextStoreTextComposition.cs
- FamilyTypeface.cs
- XmlWriter.cs
- ReadOnlyTernaryTree.cs
- TextElementCollectionHelper.cs
- InplaceBitmapMetadataWriter.cs
- FileDialog.cs
- BitSet.cs
- SqlCachedBuffer.cs
- TextContainerChangedEventArgs.cs
- EntityStoreSchemaGenerator.cs
- BaseValidator.cs
- hwndwrapper.cs
- SingleAnimationUsingKeyFrames.cs
- BitmapCodecInfoInternal.cs
- RecordBuilder.cs
- ErrorTableItemStyle.cs
- Main.cs
- MaterializeFromAtom.cs
- elementinformation.cs
- XmlArrayItemAttributes.cs
- OpenTypeCommon.cs
- DisplayInformation.cs
- BaseUriHelper.cs
- BinaryNegotiation.cs
- LoadWorkflowByInstanceKeyCommand.cs
- metadatamappinghashervisitor.cs
- PerformanceCounterPermissionEntryCollection.cs
- ListViewGroup.cs
- AppendHelper.cs
- RadialGradientBrush.cs
- MexHttpBindingCollectionElement.cs
- ForwardPositionQuery.cs
- Stack.cs
- SchemaNotation.cs
- ExecutionEngineException.cs
- SafeFileMapViewHandle.cs
- CancelEventArgs.cs
- ExtenderProvidedPropertyAttribute.cs
- GestureRecognitionResult.cs
- ExceptionUtil.cs
- TemplateControlBuildProvider.cs
- HttpWebRequest.cs
- RemoteDebugger.cs
- ScrollBarAutomationPeer.cs
- ButtonColumn.cs
- Typography.cs
- MetadataLocation.cs
- ConfigXmlElement.cs
- EntityContainerEntitySetDefiningQuery.cs
- ImageField.cs
- SqlDependency.cs
- ObjectHandle.cs
- RegexParser.cs
- _Connection.cs
- BuildProviderUtils.cs
- DurableRuntimeValidator.cs
- MatchingStyle.cs
- DocumentEventArgs.cs
- DefaultTextStore.cs
- WindowsEditBoxRange.cs
- HttpPostLocalhostServerProtocol.cs
- SmtpNetworkElement.cs
- ListBindableAttribute.cs
- ISessionStateStore.cs
- Events.cs
- ProgressBarHighlightConverter.cs
- FigureParaClient.cs
- PropertyPathConverter.cs
- SqlReferenceCollection.cs
- VideoDrawing.cs