Code:
/ DotNET / DotNET / 8.0 / untmp / WIN_WINDOWS / lh_tools_devdiv_wpf / Windows / wcp / Core / System / Windows / Media3D / Converters / Generated / Point4DValueSerializer.cs / 1 / Point4DValueSerializer.cs
//---------------------------------------------------------------------------- // //// Copyright (C) Microsoft Corporation. All rights reserved. // // // This file was generated, please do not edit it directly. // // Please see [....]/default.aspx/Microsoft.Projects.Avalon/MilCodeGen.html for more information. // //--------------------------------------------------------------------------- using MS.Internal; using MS.Internal.Collections; using MS.Internal.PresentationCore; using MS.Utility; using System; using System.Collections; using System.Collections.Generic; using System.ComponentModel; using System.ComponentModel.Design.Serialization; using System.Diagnostics; using System.Globalization; using System.Reflection; using System.Runtime.InteropServices; using System.Text; using System.Windows.Markup; using System.Windows.Media.Media3D.Converters; using System.Windows.Media; using System.Windows.Media.Animation; using System.Windows.Media.Composition; using System.Security; using System.Security.Permissions; using SR=MS.Internal.PresentationCore.SR; using SRID=MS.Internal.PresentationCore.SRID; using System.Windows.Media.Imaging; #pragma warning disable 1634, 1691 // suppressing PreSharp warnings namespace System.Windows.Media.Media3D.Converters { ////// Point4DValueSerializer - ValueSerializer class for converting instances of strings to and from Point4D instances /// This is used by the MarkupWriter class. /// public class Point4DValueSerializer : ValueSerializer { ////// Returns true. /// public override bool CanConvertFromString(string value, IValueSerializerContext context) { return true; } ////// Returns true if the given value can be converted into a string /// public override bool CanConvertToString(object value, IValueSerializerContext context) { // Validate the input type if (!(value is Point4D)) { throw new ArgumentException(SR.Get(SRID.General_Expected_Type, "Point4D"), "value"); } return true; } ////// Converts a string into a Point4D. /// public override object ConvertFromString(string value, IValueSerializerContext context) { if (value != null) { return Point4D.Parse(value ); } else { return base.ConvertFromString( value, context ); } } ////// Converts the value into a string. /// public override string ConvertToString(object value, IValueSerializerContext context) { if (value is Point4D) { Point4D instance = (Point4D) value; #pragma warning suppress 6506 // instance is obviously not null return instance.ConvertToString(null, CultureInfo.GetCultureInfo("en-us") ); } return base.ConvertToString(value, context); } } } // 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
- CountdownEvent.cs
- XmlNamespaceDeclarationsAttribute.cs
- BaseDataList.cs
- SafeEventLogWriteHandle.cs
- TextRangeProviderWrapper.cs
- DataSourceXmlAttributeAttribute.cs
- CustomAttributeSerializer.cs
- UIPropertyMetadata.cs
- BamlTreeUpdater.cs
- MetadataConversionError.cs
- Panel.cs
- WebConfigurationManager.cs
- AccessText.cs
- EntityDataSourceWizardForm.cs
- BitmapData.cs
- RadioButtonBaseAdapter.cs
- PageTheme.cs
- SettingsPropertyValue.cs
- SpellCheck.cs
- Mapping.cs
- TargetParameterCountException.cs
- TypeConverterHelper.cs
- BlockCollection.cs
- TableLayoutSettings.cs
- RawStylusActions.cs
- BypassElementCollection.cs
- baseaxisquery.cs
- ConnectionStringsExpressionBuilder.cs
- SqlXml.cs
- RestHandlerFactory.cs
- DateTimeFormat.cs
- DefaultMemberAttribute.cs
- ContainerAction.cs
- ImageCreator.cs
- SqlError.cs
- SHA256.cs
- ToggleButton.cs
- RemotingService.cs
- StatusBarPanelClickEvent.cs
- CodeNamespace.cs
- CommandPlan.cs
- StateBag.cs
- ListItemViewControl.cs
- WebServiceFault.cs
- AssertUtility.cs
- ConfigUtil.cs
- Compiler.cs
- Missing.cs
- WindowsPen.cs
- ListBase.cs
- SystemThemeKey.cs
- ReflectionPermission.cs
- BehaviorEditorPart.cs
- ByteStack.cs
- BulletedList.cs
- FlowLayoutPanel.cs
- WindowPatternIdentifiers.cs
- ControlBuilderAttribute.cs
- ReadOnlyCollection.cs
- RegisteredArrayDeclaration.cs
- EntityWrapperFactory.cs
- CodeNamespaceImport.cs
- JoinCqlBlock.cs
- HashHelper.cs
- FormatPage.cs
- PageVisual.cs
- PolicyChain.cs
- StackSpiller.cs
- WebReferencesBuildProvider.cs
- DataGridViewDataConnection.cs
- Collection.cs
- RepeatBehavior.cs
- BaseDataList.cs
- EventProviderWriter.cs
- WpfWebRequestHelper.cs
- XmlNamespaceMappingCollection.cs
- HttpConfigurationSystem.cs
- AppDomainCompilerProxy.cs
- HwndSourceKeyboardInputSite.cs
- PeerNameRecordCollection.cs
- ImportContext.cs
- LongValidatorAttribute.cs
- TextDecorations.cs
- mediaeventshelper.cs
- ThreadStartException.cs
- TraceContext.cs
- MessageSmuggler.cs
- UInt64.cs
- DynamicUpdateCommand.cs
- Matrix3DStack.cs
- COM2IManagedPerPropertyBrowsingHandler.cs
- NameTable.cs
- TextServicesPropertyRanges.cs
- XmlUrlEditor.cs
- ImageMap.cs
- TypeLibConverter.cs
- Process.cs
- BaseTemplateBuildProvider.cs
- ECDiffieHellmanCngPublicKey.cs
- X509AsymmetricSecurityKey.cs