Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Data / System / Data / Range.cs / 1305376 / 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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- RemotingException.cs
- XmlRawWriter.cs
- ListViewSelectEventArgs.cs
- mansign.cs
- TextDecorationCollection.cs
- SecurityPolicySection.cs
- SafeProcessHandle.cs
- SiteMapNodeItemEventArgs.cs
- GlyphCache.cs
- TableLayout.cs
- RtType.cs
- UnknownWrapper.cs
- CallbackDebugBehavior.cs
- fixedPageContentExtractor.cs
- RectangleF.cs
- XmlSchemaComplexContent.cs
- ToolBar.cs
- RightsManagementInformation.cs
- CommandID.cs
- MembershipUser.cs
- SqlUtils.cs
- QilPatternVisitor.cs
- SvcMapFileSerializer.cs
- GridViewRow.cs
- DiagnosticTrace.cs
- AppDomainInstanceProvider.cs
- DataRecordInfo.cs
- Drawing.cs
- Literal.cs
- PerfCounterSection.cs
- SqlTypeConverter.cs
- DeflateEmulationStream.cs
- HttpCookieCollection.cs
- EntityTransaction.cs
- HostingEnvironmentSection.cs
- FixedTextContainer.cs
- ContentPlaceHolderDesigner.cs
- EmptyStringExpandableObjectConverter.cs
- LinearQuaternionKeyFrame.cs
- UnmanagedMemoryStreamWrapper.cs
- XPathScanner.cs
- ActiveXMessageFormatter.cs
- XamlTemplateSerializer.cs
- SQLStringStorage.cs
- GatewayIPAddressInformationCollection.cs
- StateDesigner.cs
- MenuRendererClassic.cs
- _AuthenticationState.cs
- LowerCaseStringConverter.cs
- JsonSerializer.cs
- ListBindingConverter.cs
- RadioButtonPopupAdapter.cs
- PathTooLongException.cs
- Range.cs
- BitmapScalingModeValidation.cs
- nulltextnavigator.cs
- VsPropertyGrid.cs
- XPathMessageFilterTable.cs
- AuthorizationContext.cs
- InputScopeNameConverter.cs
- MarkupCompiler.cs
- MethodResolver.cs
- StorageBasedPackageProperties.cs
- CodeTypeReferenceExpression.cs
- ErrorHandler.cs
- WindowAutomationPeer.cs
- Automation.cs
- EnumBuilder.cs
- BmpBitmapDecoder.cs
- AdjustableArrowCap.cs
- DayRenderEvent.cs
- XamlGridLengthSerializer.cs
- CustomError.cs
- HashSetEqualityComparer.cs
- XmlCharCheckingWriter.cs
- UserValidatedEventArgs.cs
- QueryAsyncResult.cs
- Preprocessor.cs
- NavigationFailedEventArgs.cs
- WarningException.cs
- SchemaDeclBase.cs
- X509ChainPolicy.cs
- MatrixConverter.cs
- StreamWithDictionary.cs
- ObjectViewListener.cs
- APCustomTypeDescriptor.cs
- OleDbPropertySetGuid.cs
- WebPartConnection.cs
- FlatButtonAppearance.cs
- TextViewBase.cs
- ConnectionStringSettings.cs
- MissingManifestResourceException.cs
- DependencySource.cs
- WindowsUserNameSecurityTokenAuthenticator.cs
- SourceFileInfo.cs
- NavigationEventArgs.cs
- NumberFunctions.cs
- QilTernary.cs
- FixedSOMContainer.cs
- WebPageTraceListener.cs