Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Net / System / Net / NetworkInformation / SystemTcpStatistics.cs / 1305376 / SystemTcpStatistics.cs
////// namespace System.Net.NetworkInformation { using System.Net.Sockets; using System; using System.ComponentModel; /// /// Provides support for ip configuation information and statistics. /// Tcp specific statistics. internal class SystemTcpStatistics:TcpStatistics { MibTcpStats stats; private SystemTcpStatistics(){} internal SystemTcpStatistics(AddressFamily family){ uint result; if (!ComNetOS.IsPostWin2K){ if (family!= AddressFamily.InterNetwork){ throw new PlatformNotSupportedException(SR.GetString(SR.WinXPRequired)); } result = UnsafeNetInfoNativeMethods.GetTcpStatistics(out stats); } else result = UnsafeNetInfoNativeMethods.GetTcpStatisticsEx(out stats, family); if (result != IpHelperErrors.Success) { throw new NetworkInformationException((int)result); } } public override long MinimumTransmissionTimeout{get {return stats.minimumRetransmissionTimeOut;}} public override long MaximumTransmissionTimeout{get {return stats.maximumRetransmissionTimeOut;}} public override long MaximumConnections{get {return stats.maximumConnections;}} public override long ConnectionsInitiated{get {return stats.activeOpens;}} public override long ConnectionsAccepted{get {return stats.passiveOpens;}}// is this true? We should check public override long FailedConnectionAttempts{get {return stats.failedConnectionAttempts;}} public override long ResetConnections{get {return stats.resetConnections;}} public override long CurrentConnections{get {return stats.currentConnections;}} public override long SegmentsReceived{get {return stats.segmentsReceived;}} public override long SegmentsSent{get {return stats.segmentsSent;}} public override long SegmentsResent{get {return stats.segmentsResent;}} public override long ErrorsReceived{get {return stats.errorsReceived;}} public override long ResetsSent{get {return stats.segmentsSentWithReset;}} public override long CumulativeConnections{get {return stats.cumulativeConnections;}} } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- EventRecord.cs
- BackgroundWorker.cs
- SerializationStore.cs
- EntityDataSourceContextCreatingEventArgs.cs
- WindowsImpersonationContext.cs
- ProfileEventArgs.cs
- XmlNamespaceMappingCollection.cs
- PresentationTraceSources.cs
- CompModSwitches.cs
- NameTable.cs
- Int32AnimationUsingKeyFrames.cs
- LinearQuaternionKeyFrame.cs
- OracleNumber.cs
- EntryPointNotFoundException.cs
- BaseTemplateCodeDomTreeGenerator.cs
- CriticalFileToken.cs
- Property.cs
- ThrowHelper.cs
- MailAddress.cs
- OpCopier.cs
- TemplateField.cs
- DoubleCollectionValueSerializer.cs
- BufferedGraphics.cs
- DependencyPropertyKind.cs
- Vars.cs
- ErrorTableItemStyle.cs
- AssemblyCollection.cs
- CallbackHandler.cs
- SocketManager.cs
- HeaderedItemsControl.cs
- GridViewRowPresenter.cs
- ConditionalDesigner.cs
- ButtonChrome.cs
- embossbitmapeffect.cs
- FixUp.cs
- IdentityModelDictionary.cs
- ImageField.cs
- SqlCacheDependencyDatabase.cs
- RSAProtectedConfigurationProvider.cs
- AttributeCollection.cs
- CodeDirectionExpression.cs
- DocumentOrderQuery.cs
- ServiceOperationHelpers.cs
- CustomTypeDescriptor.cs
- ToolboxDataAttribute.cs
- PriorityItem.cs
- MobileCategoryAttribute.cs
- XmlHelper.cs
- OutputCacheSettings.cs
- MarshalByValueComponent.cs
- ViewLoader.cs
- HtmlInputFile.cs
- SecurityCriticalDataForSet.cs
- SoapIncludeAttribute.cs
- OpenFileDialog.cs
- DateTimePickerDesigner.cs
- ToolboxComponentsCreatingEventArgs.cs
- MultitargetingHelpers.cs
- ImmutableCollection.cs
- Rules.cs
- SplashScreenNativeMethods.cs
- MessageSmuggler.cs
- StringValueSerializer.cs
- XPathNavigatorReader.cs
- ListViewDeleteEventArgs.cs
- _LoggingObject.cs
- FixedSOMTextRun.cs
- InstanceDataCollection.cs
- RankException.cs
- EncryptedReference.cs
- SystemKeyConverter.cs
- SqlDataSourceEnumerator.cs
- OdbcErrorCollection.cs
- PrincipalPermissionMode.cs
- Object.cs
- DataGridToolTip.cs
- SqlMethodAttribute.cs
- CollectionViewGroup.cs
- StrongNameHelpers.cs
- HttpResponse.cs
- Errors.cs
- SoapAttributeOverrides.cs
- Panel.cs
- PageAsyncTaskManager.cs
- GACIdentityPermission.cs
- NativeMethodsOther.cs
- SpecialNameAttribute.cs
- SymbolEqualComparer.cs
- ServicesExceptionNotHandledEventArgs.cs
- FrameworkElementFactory.cs
- DoubleLink.cs
- ConfigXmlWhitespace.cs
- SqlBooleanizer.cs
- SimplePropertyEntry.cs
- FileBasedResourceGroveler.cs
- CommentEmitter.cs
- OleDbEnumerator.cs
- SHA1.cs
- ProxyHwnd.cs
- ResourceAttributes.cs