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
- ChildTable.cs
- DynamicResourceExtensionConverter.cs
- EndOfStreamException.cs
- SQLDoubleStorage.cs
- ProfileGroupSettingsCollection.cs
- HashCodeCombiner.cs
- XmlSchemaSimpleContentExtension.cs
- SecurityContext.cs
- XmlNodeChangedEventArgs.cs
- SpellCheck.cs
- Light.cs
- CryptoProvider.cs
- SizeAnimationClockResource.cs
- COM2ExtendedBrowsingHandler.cs
- JavaScriptSerializer.cs
- XmlDataProvider.cs
- DataGridViewCell.cs
- ObjectItemCollection.cs
- MenuCommands.cs
- EntityDataSourceStatementEditorForm.cs
- PeerPresenceInfo.cs
- ADMembershipProvider.cs
- RectIndependentAnimationStorage.cs
- DataSetMappper.cs
- JsonGlobals.cs
- PixelShader.cs
- ProxyHwnd.cs
- AtomMaterializerLog.cs
- AssemblyResourceLoader.cs
- PartitionedDataSource.cs
- HttpWebRequestElement.cs
- Error.cs
- EntityDataSourceContainerNameItem.cs
- QilVisitor.cs
- TraceSection.cs
- SubstitutionList.cs
- SingleConverter.cs
- COM2ICategorizePropertiesHandler.cs
- UnsafeNativeMethods.cs
- Number.cs
- AppDomainEvidenceFactory.cs
- PositiveTimeSpanValidator.cs
- RadioButtonList.cs
- Authorization.cs
- WorkflowQueuingService.cs
- SystemSounds.cs
- ContentTextAutomationPeer.cs
- PropertyChangingEventArgs.cs
- EventItfInfo.cs
- BoundPropertyEntry.cs
- Semaphore.cs
- ClientScriptManagerWrapper.cs
- HttpWebResponse.cs
- SamlAssertionKeyIdentifierClause.cs
- DataServiceCollectionOfT.cs
- ConfigurationManagerInternalFactory.cs
- Pkcs9Attribute.cs
- XmlWriterSettings.cs
- InfoCardProofToken.cs
- MetadataItemEmitter.cs
- IsolatedStorageFilePermission.cs
- StructuredProperty.cs
- CellParagraph.cs
- AutomationPeer.cs
- SafeFileMappingHandle.cs
- FontStretch.cs
- BindingFormattingDialog.cs
- NamedElement.cs
- ToolStripItemEventArgs.cs
- BitmapEffectInputConnector.cs
- DataGridTableStyleMappingNameEditor.cs
- TransformValueSerializer.cs
- DictionaryBase.cs
- PageContent.cs
- PersonalizationStateInfo.cs
- XmlObjectSerializerWriteContextComplex.cs
- CreateUserErrorEventArgs.cs
- IsolatedStorageFilePermission.cs
- GradientBrush.cs
- NameValueFileSectionHandler.cs
- ObjectDisposedException.cs
- WebPartUserCapability.cs
- TranslateTransform.cs
- OracleBoolean.cs
- DynamicValueConverter.cs
- PartialTrustVisibleAssembly.cs
- XomlCompilerResults.cs
- BatchStream.cs
- RelationshipWrapper.cs
- CommentAction.cs
- WorkflowDesigner.cs
- ProcessInputEventArgs.cs
- PartitionedStreamMerger.cs
- ConfigurationPropertyAttribute.cs
- MonitorWrapper.cs
- Form.cs
- SqlProcedureAttribute.cs
- DataControlFieldHeaderCell.cs
- oledbmetadatacollectionnames.cs
- TemplateControlParser.cs