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
- ActivityExecutor.cs
- ADMembershipProvider.cs
- LocalizedNameDescriptionPair.cs
- TrustVersion.cs
- PartialList.cs
- DataGridViewCellStyleChangedEventArgs.cs
- SchemaContext.cs
- CodeCastExpression.cs
- ToolStripDropDownItem.cs
- LinearQuaternionKeyFrame.cs
- XmlSchemaParticle.cs
- ListControlBoundActionList.cs
- PolicyStatement.cs
- DataTableReader.cs
- EventMap.cs
- OleDbCommandBuilder.cs
- HtmlTable.cs
- CellTreeNodeVisitors.cs
- TreeNodeBinding.cs
- ActivationServices.cs
- HttpCacheVary.cs
- BadImageFormatException.cs
- ManipulationDeltaEventArgs.cs
- ImageAnimator.cs
- ManagedFilter.cs
- ConfigXmlText.cs
- _Rfc2616CacheValidators.cs
- LabelLiteral.cs
- ProfileProvider.cs
- XmlArrayItemAttributes.cs
- ParameterCollection.cs
- HtmlInputHidden.cs
- EdmRelationshipRoleAttribute.cs
- BufferBuilder.cs
- KnownIds.cs
- SelectionList.cs
- ToolbarAUtomationPeer.cs
- TreeNode.cs
- UserControlBuildProvider.cs
- glyphs.cs
- TextServicesPropertyRanges.cs
- SpinLock.cs
- UiaCoreProviderApi.cs
- XPathAxisIterator.cs
- ChangePassword.cs
- OpenFileDialog.cs
- QilXmlWriter.cs
- BuildProvider.cs
- GeometryDrawing.cs
- TreeBuilder.cs
- ExponentialEase.cs
- CompositionAdorner.cs
- PanelStyle.cs
- Filter.cs
- CodeGroup.cs
- SmtpNtlmAuthenticationModule.cs
- GroupQuery.cs
- SafeSecurityHandles.cs
- Size3DValueSerializer.cs
- EnumConverter.cs
- LogFlushAsyncResult.cs
- FieldToken.cs
- OLEDB_Util.cs
- IsolationInterop.cs
- LoopExpression.cs
- ProcessModelSection.cs
- JoinGraph.cs
- ParameterCollection.cs
- TrackingParticipant.cs
- ComponentTray.cs
- IPHostEntry.cs
- AnnotationComponentManager.cs
- PriorityQueue.cs
- _ProxyRegBlob.cs
- SqlTopReducer.cs
- FileCodeGroup.cs
- SortedSetDebugView.cs
- ToolStripSplitStackLayout.cs
- ExclusiveTcpListener.cs
- PostBackOptions.cs
- Fonts.cs
- SqlUtils.cs
- XXXInfos.cs
- VisualStyleElement.cs
- SqlErrorCollection.cs
- TimeManager.cs
- MultiView.cs
- CodeArgumentReferenceExpression.cs
- ParseHttpDate.cs
- PersistenceParticipant.cs
- ToolStripSettings.cs
- HttpListenerException.cs
- ConfigXmlCDataSection.cs
- TableRow.cs
- PrePostDescendentsWalker.cs
- TextAutomationPeer.cs
- Knowncolors.cs
- DictionaryKeyPropertyAttribute.cs
- BindingCollection.cs
- SqlDataSourceStatusEventArgs.cs