Code:
/ Dotnetfx_Vista_SP2 / Dotnetfx_Vista_SP2 / 8.0.50727.4016 / DEVDIV / depot / DevDiv / releases / whidbey / NetFxQFE / ndp / fx / src / Data / System / Data / Range.cs / 1 / Range.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //[....] //[....] //----------------------------------------------------------------------------- namespace System.Data { using System; internal struct Range { private int min; private int max; private bool isNotNull; // zero bit pattern represents null public Range(int min, int max) { if (min > max) { throw ExceptionBuilder.RangeArgument(min, max); } this.min = min; this.max = max; isNotNull = true; } public int Count { get { if (IsNull) return 0; return max - min + 1; } } public bool IsNull { get { return !isNotNull; } } public int Max { get { CheckNull(); return max; } } public int Min { get { CheckNull(); return min; } } internal void CheckNull() { if (this.IsNull) { throw ExceptionBuilder.NullRange(); } } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //[....] //[....] //[....] //----------------------------------------------------------------------------- namespace System.Data { using System; internal struct Range { private int min; private int max; private bool isNotNull; // zero bit pattern represents null public Range(int min, int max) { if (min > max) { throw ExceptionBuilder.RangeArgument(min, max); } this.min = min; this.max = max; isNotNull = true; } public int Count { get { if (IsNull) return 0; return max - min + 1; } } public bool IsNull { get { return !isNotNull; } } public int Max { get { CheckNull(); return max; } } public int Min { get { CheckNull(); return min; } } internal void CheckNull() { if (this.IsNull) { throw ExceptionBuilder.NullRange(); } } } } // 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
- ElementHost.cs
- Size.cs
- ErrorStyle.cs
- PrivilegeNotHeldException.cs
- SecurityTokenAuthenticator.cs
- CategoryAttribute.cs
- OpenTypeLayoutCache.cs
- HttpProcessUtility.cs
- ReceiveMessageRecord.cs
- ContextStaticAttribute.cs
- InternalControlCollection.cs
- LineServicesRun.cs
- FunctionDescription.cs
- GenericEnumerator.cs
- WebResponse.cs
- CheckBoxField.cs
- ObjectItemAttributeAssemblyLoader.cs
- DataBinder.cs
- BaseHashHelper.cs
- TextElement.cs
- TypedTableHandler.cs
- ObjectPersistData.cs
- PersonalizablePropertyEntry.cs
- ImageIndexConverter.cs
- DBDataPermission.cs
- Mutex.cs
- TdsValueSetter.cs
- MenuItemBindingCollection.cs
- WebPartMenuStyle.cs
- EntityProxyTypeInfo.cs
- Activator.cs
- TemplateBuilder.cs
- DesignerOptionService.cs
- OdbcFactory.cs
- CodeGroup.cs
- TypeToken.cs
- NullableConverter.cs
- MdiWindowListItemConverter.cs
- UriExt.cs
- NamespaceInfo.cs
- ListItem.cs
- StyleCollection.cs
- KeyGestureValueSerializer.cs
- Aggregates.cs
- Utils.cs
- NumberAction.cs
- PersonalizationAdministration.cs
- MonitorWrapper.cs
- Activator.cs
- RunClient.cs
- DbProviderConfigurationHandler.cs
- FunctionParameter.cs
- WSHttpBindingElement.cs
- SqlUtil.cs
- Profiler.cs
- Parsers.cs
- FtpCachePolicyElement.cs
- RunWorkerCompletedEventArgs.cs
- Collection.cs
- PersonalizationAdministration.cs
- DivideByZeroException.cs
- DateTimeFormatInfo.cs
- _LocalDataStore.cs
- DebuggerAttributes.cs
- DemultiplexingDispatchMessageFormatter.cs
- DateTimeUtil.cs
- ExeContext.cs
- GradientStop.cs
- XamlToRtfParser.cs
- InvalidContentTypeException.cs
- IsolatedStorageException.cs
- DataGridViewCell.cs
- ClientData.cs
- MissingSatelliteAssemblyException.cs
- Command.cs
- DNS.cs
- DictionaryBase.cs
- translator.cs
- DecoderFallbackWithFailureFlag.cs
- WindowsGraphicsWrapper.cs
- RoleServiceManager.cs
- TagPrefixInfo.cs
- RequestUriProcessor.cs
- OneOfTypeConst.cs
- WaitHandleCannotBeOpenedException.cs
- TrackingProfile.cs
- LinkUtilities.cs
- ControlEvent.cs
- ScrollBarAutomationPeer.cs
- CodeRemoveEventStatement.cs
- ContentValidator.cs
- BitmapCacheBrush.cs
- SoapElementAttribute.cs
- SqlPersonalizationProvider.cs
- ListMarkerSourceInfo.cs
- HitTestParameters3D.cs
- SoapAttributes.cs
- DictionarySectionHandler.cs
- WebResourceAttribute.cs
- FragmentQuery.cs