Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Net / System / Net / NetworkInformation / SystemTcpStatistics.cs / 1 / 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;}} } }
Link Menu

This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- _ListenerAsyncResult.cs
- ObjectParameter.cs
- StylusTip.cs
- MethodAccessException.cs
- CompareValidator.cs
- Expander.cs
- VBIdentifierDesigner.xaml.cs
- RowCache.cs
- UshortList2.cs
- KeyPressEvent.cs
- ParamArrayAttribute.cs
- ListParagraph.cs
- MapPathBasedVirtualPathProvider.cs
- HtmlInputText.cs
- TypeHelper.cs
- FilterableAttribute.cs
- SubclassTypeValidator.cs
- ProcessModuleCollection.cs
- QueryContinueDragEventArgs.cs
- ReflectPropertyDescriptor.cs
- XpsSerializationManagerAsync.cs
- XmlByteStreamWriter.cs
- WindowsNonControl.cs
- RelativeSource.cs
- InvalidPrinterException.cs
- MembershipSection.cs
- ExecutionScope.cs
- TextSchema.cs
- SmtpDigestAuthenticationModule.cs
- Camera.cs
- XamlSerializerUtil.cs
- DataContract.cs
- AutomationAttributeInfo.cs
- WebEventCodes.cs
- SmtpAuthenticationManager.cs
- CookielessData.cs
- ListBox.cs
- StrokeNode.cs
- VariableDesigner.xaml.cs
- DateTimePicker.cs
- ClientRoleProvider.cs
- RenderTargetBitmap.cs
- QuotedPairReader.cs
- IsolatedStorageFilePermission.cs
- ArgumentValidation.cs
- ObjectConverter.cs
- TokenBasedSet.cs
- ButtonBaseAdapter.cs
- TreeNodeClickEventArgs.cs
- TrackingWorkflowEventArgs.cs
- TransportDefaults.cs
- MDIClient.cs
- DataColumnMappingCollection.cs
- AddInBase.cs
- PropertyBuilder.cs
- SHA512Cng.cs
- ObjectPersistData.cs
- FixedDocument.cs
- BreakRecordTable.cs
- ZipQueryOperator.cs
- HotSpotCollection.cs
- Stack.cs
- CompilerError.cs
- ToolStripDropDownButton.cs
- XamlSerializerUtil.cs
- StateValidator.cs
- PagesSection.cs
- CodePageUtils.cs
- SqlRowUpdatingEvent.cs
- XmlReaderSettings.cs
- ColorMap.cs
- PlatformCulture.cs
- Trace.cs
- DataGridHeaderBorder.cs
- InternalsVisibleToAttribute.cs
- SimpleFieldTemplateUserControl.cs
- ProjectionPath.cs
- Resources.Designer.cs
- ToolboxItemFilterAttribute.cs
- HttpHandlersSection.cs
- PenThreadWorker.cs
- FontStretches.cs
- LockCookie.cs
- GcSettings.cs
- PackageRelationship.cs
- DataGridCheckBoxColumn.cs
- DelegateSerializationHolder.cs
- NativeWindow.cs
- Helper.cs
- counter.cs
- HtmlSelectionListAdapter.cs
- EditorPart.cs
- DataBindingCollectionConverter.cs
- UnaryNode.cs
- SmtpFailedRecipientsException.cs
- ResourcePart.cs
- SecurityUtils.cs
- PaintEvent.cs
- MethodImplAttribute.cs
- WrappedReader.cs