Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / CompMod / System / ComponentModel / Int16Converter.cs / 1305376 / Int16Converter.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.ComponentModel { using Microsoft.Win32; using System.Diagnostics; using System.Globalization; using System.Runtime.InteropServices; using System.Runtime.Remoting; using System.Runtime.Serialization.Formatters; using System.Security.Permissions; ////// [HostProtection(SharedState = true)] public class Int16Converter : BaseNumberConverter { ///Provides a type converter to convert 16-bit signed integer objects to and /// from various other representations. ////// The Type this converter is targeting (e.g. Int16, UInt32, etc.) /// internal override Type TargetType { get { return typeof(Int16); } } ////// Convert the given value to a string using the given radix /// internal override object FromString(string value, int radix) { return Convert.ToInt16(value, radix); } ////// Convert the given value to a string using the given CultureInfo /// internal override object FromString(string value, CultureInfo culture){ return Int16.Parse(value, culture); } ////// Convert the given value to a string using the given formatInfo /// internal override object FromString(string value, NumberFormatInfo formatInfo) { return Int16.Parse(value, NumberStyles.Integer, formatInfo); } ////// Convert the given value from a string using the given formatInfo /// internal override string ToString(object value, NumberFormatInfo formatInfo) { return ((Int16)value).ToString("G", formatInfo); } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- InheritablePropertyChangeInfo.cs
- XmlAtomicValue.cs
- LessThan.cs
- OleStrCAMarshaler.cs
- PathTooLongException.cs
- Columns.cs
- ShapeTypeface.cs
- Model3D.cs
- RtfNavigator.cs
- StylusOverProperty.cs
- RMEnrollmentPage1.cs
- Queue.cs
- FixedPageProcessor.cs
- ToolStripContentPanel.cs
- AssemblyBuilderData.cs
- SqlIdentifier.cs
- HashHelper.cs
- DataGridViewImageCell.cs
- SessionParameter.cs
- HeaderCollection.cs
- EventSinkActivityDesigner.cs
- WindowsProgressbar.cs
- SafeRightsManagementPubHandle.cs
- DataGridViewAutoSizeColumnsModeEventArgs.cs
- COM2ExtendedBrowsingHandler.cs
- GeometryModel3D.cs
- HttpTransportSecurity.cs
- SqlOuterApplyReducer.cs
- CatalogPartChrome.cs
- OleDbEnumerator.cs
- PrintPreviewDialog.cs
- CultureInfoConverter.cs
- HttpServerVarsCollection.cs
- GetPageCompletedEventArgs.cs
- RowBinding.cs
- GuidTagList.cs
- LinkLabelLinkClickedEvent.cs
- FileDialog_Vista.cs
- ObjectDataSourceDisposingEventArgs.cs
- ProfileGroupSettings.cs
- DataGridViewCellToolTipTextNeededEventArgs.cs
- EdmItemCollection.cs
- MatrixIndependentAnimationStorage.cs
- ModuleConfigurationInfo.cs
- _SingleItemRequestCache.cs
- AnnotationComponentManager.cs
- DriveInfo.cs
- ContentOperations.cs
- BuildProvider.cs
- BasicKeyConstraint.cs
- TypeConstant.cs
- DateTimeOffset.cs
- TextModifier.cs
- MainMenu.cs
- IFlowDocumentViewer.cs
- EntitySqlException.cs
- WebPartHelpVerb.cs
- OleDbRowUpdatedEvent.cs
- TagMapInfo.cs
- ClassImporter.cs
- Vertex.cs
- hresults.cs
- DocumentGrid.cs
- TextEndOfSegment.cs
- PackagingUtilities.cs
- XmlSchemaProviderAttribute.cs
- SparseMemoryStream.cs
- ListCollectionView.cs
- MultiSelectRootGridEntry.cs
- DotAtomReader.cs
- TemplateControl.cs
- querybuilder.cs
- Trace.cs
- XamlVector3DCollectionSerializer.cs
- BamlTreeNode.cs
- sortedlist.cs
- PlatformCulture.cs
- ViewBase.cs
- EntityViewContainer.cs
- TypeUtil.cs
- ApplicationSecurityInfo.cs
- ReachFixedDocumentSerializerAsync.cs
- VirtualDirectoryMapping.cs
- MimeParameter.cs
- RawStylusInputCustomDataList.cs
- GridViewCancelEditEventArgs.cs
- ProgramNode.cs
- CodeAccessSecurityEngine.cs
- SapiInterop.cs
- PartialCachingControl.cs
- SerializationTrace.cs
- Bidi.cs
- XmlEncodedRawTextWriter.cs
- ContextStack.cs
- BufferedStream.cs
- CompModSwitches.cs
- OleServicesContext.cs
- CompareValidator.cs
- Privilege.cs
- externdll.cs