Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / CompMod / System / ComponentModel / SByteConverter.cs / 1 / SByteConverter.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 SByteConverter : BaseNumberConverter { ///Provides a /// type converter to convert 8-bit unsigned /// 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(SByte); } } ////// Convert the given value to a string using the given radix /// internal override object FromString(string value, int radix) { return Convert.ToSByte(value, radix); } ////// Convert the given value to a string using the given formatInfo /// internal override object FromString(string value, NumberFormatInfo formatInfo) { return SByte.Parse(value, NumberStyles.Integer, formatInfo); } ////// Convert the given value to a string using the given CultureInfo /// internal override object FromString(string value, CultureInfo culture){ return SByte.Parse(value, culture); } ////// Convert the given value from a string using the given formatInfo /// internal override string ToString(object value, NumberFormatInfo formatInfo) { return ((SByte)value).ToString("G", formatInfo); } } }
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- Region.cs
- UnsafeNativeMethods.cs
- TrustManagerPromptUI.cs
- _NegoState.cs
- LinkClickEvent.cs
- CFStream.cs
- BuildProviderCollection.cs
- XmlSignificantWhitespace.cs
- RSAPKCS1SignatureDeformatter.cs
- Clock.cs
- StylusPlugInCollection.cs
- ProfileServiceManager.cs
- DesignerCategoryAttribute.cs
- RepeaterItemEventArgs.cs
- PrinterUnitConvert.cs
- QualifierSet.cs
- DBConcurrencyException.cs
- XPathNodeInfoAtom.cs
- WebPartZoneDesigner.cs
- DataGridViewRowPostPaintEventArgs.cs
- PersistChildrenAttribute.cs
- StatusBarAutomationPeer.cs
- RootAction.cs
- Constants.cs
- HttpStreamXmlDictionaryReader.cs
- DropTarget.cs
- ListBox.cs
- DynamicAttribute.cs
- DrawingContextWalker.cs
- ObjectDataProvider.cs
- HtmlMobileTextWriter.cs
- DbRetry.cs
- InlineCollection.cs
- TextSearch.cs
- DirtyTextRange.cs
- UnSafeCharBuffer.cs
- ButtonAutomationPeer.cs
- DataListItemCollection.cs
- WebExceptionStatus.cs
- SpecialNameAttribute.cs
- CommandManager.cs
- HtmlControlAdapter.cs
- XamlWriter.cs
- RegionInfo.cs
- PassportAuthentication.cs
- WebPartDisplayModeCancelEventArgs.cs
- ListItemDetailViewAttribute.cs
- HtmlSelect.cs
- RestClientProxyHandler.cs
- ThreadStateException.cs
- XmlIlTypeHelper.cs
- ExpressionHelper.cs
- CodeDirectionExpression.cs
- FolderLevelBuildProviderCollection.cs
- SqlCachedBuffer.cs
- ProjectionPruner.cs
- ObjectReaderCompiler.cs
- SoapElementAttribute.cs
- Stacktrace.cs
- HttpListenerRequestUriBuilder.cs
- HtmlTable.cs
- FullTextBreakpoint.cs
- OutputScopeManager.cs
- DynamicILGenerator.cs
- Highlights.cs
- BypassElement.cs
- ServiceInstanceProvider.cs
- SmiTypedGetterSetter.cs
- RuleInfoComparer.cs
- BorderGapMaskConverter.cs
- SymmetricKeyWrap.cs
- DBAsyncResult.cs
- LabelExpression.cs
- Version.cs
- ColorAnimationUsingKeyFrames.cs
- TreeIterator.cs
- MappingException.cs
- PersistenceProviderElement.cs
- StoryFragments.cs
- SpecularMaterial.cs
- EpmContentDeSerializer.cs
- Calendar.cs
- DataKeyCollection.cs
- IPHostEntry.cs
- ClientApiGenerator.cs
- SocketAddress.cs
- ControlCollection.cs
- EventHandlers.cs
- RegionIterator.cs
- VisualBrush.cs
- CurrentTimeZone.cs
- Shape.cs
- HtmlElementCollection.cs
- MulticastOption.cs
- StateMachineSubscriptionManager.cs
- Vector3DCollectionConverter.cs
- ControlDesigner.cs
- StyleConverter.cs
- EmptyStringExpandableObjectConverter.cs
- validation.cs