Code:
/ FX-1434 / FX-1434 / 1.0 / untmp / whidbey / REDBITS / ndp / fx / src / Net / System / Net / NetworkInformation / PingOptions.cs / 1 / PingOptions.cs
//determines which options will be used for sending icmp requests, as well as what options //were set in the returned icmp reply. namespace System.Net.NetworkInformation { // Represent the possible ip options used for the icmp packet public class PingOptions { const int DontFragmentFlag = 2; int ttl = 128; bool dontFragment; internal PingOptions (IPOptions options) { this.ttl = options.ttl; this.dontFragment = ((options.flags & DontFragmentFlag) > 0 ? true : false); } public PingOptions (int ttl, bool dontFragment) { if (ttl <= 0) { throw new ArgumentOutOfRangeException("ttl"); } this.ttl = ttl; this.dontFragment = dontFragment; } public PingOptions () { } public int Ttl { get { return ttl; } set { if (value <= 0) { throw new ArgumentOutOfRangeException("value"); } ttl = value; //useful to discover routes } } public bool DontFragment { get { return dontFragment; } set { dontFragment = value; //useful for discovering mtu } } } }
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- EventProviderWriter.cs
- HttpProcessUtility.cs
- MultiByteCodec.cs
- ellipse.cs
- SafeSecurityHandles.cs
- ClientRuntimeConfig.cs
- MsmqIntegrationSecurity.cs
- SqlMethodCallConverter.cs
- ComponentCollection.cs
- MetadataException.cs
- XmlMembersMapping.cs
- HtmlPageAdapter.cs
- FastEncoderWindow.cs
- HttpCapabilitiesBase.cs
- TextParaClient.cs
- ToolStripDropDownItem.cs
- AstNode.cs
- Command.cs
- FlowNode.cs
- PeerFlooder.cs
- SocketInformation.cs
- ContentControl.cs
- MethodBuilder.cs
- SessionPageStateSection.cs
- DateTimeFormatInfoScanner.cs
- Line.cs
- ComplexPropertyEntry.cs
- Table.cs
- NavigatorInput.cs
- OutOfMemoryException.cs
- MulticastIPAddressInformationCollection.cs
- ConfigurationStrings.cs
- XmlSchemaSimpleTypeList.cs
- SqlDataSourceCache.cs
- StringStorage.cs
- DateTimeOffsetAdapter.cs
- KeyEvent.cs
- CircleEase.cs
- ControlParser.cs
- DateTimePickerDesigner.cs
- WmfPlaceableFileHeader.cs
- Empty.cs
- ListBoxAutomationPeer.cs
- ZipIOExtraFieldPaddingElement.cs
- SoundPlayer.cs
- Rijndael.cs
- ReliableMessagingHelpers.cs
- DataColumnCollection.cs
- ClientSettingsProvider.cs
- MobileDeviceCapabilitiesSectionHandler.cs
- TraceLog.cs
- AssemblyBuilder.cs
- OleDbCommandBuilder.cs
- FileDialogPermission.cs
- InvalidOperationException.cs
- UserControlBuildProvider.cs
- DataComponentGenerator.cs
- ScriptServiceAttribute.cs
- ResourceWriter.cs
- BatchParser.cs
- Sql8ExpressionRewriter.cs
- SecurityTokenReferenceStyle.cs
- SlipBehavior.cs
- ControllableStoryboardAction.cs
- ActivityDesignerHelper.cs
- WebHttpBindingCollectionElement.cs
- DataKeyCollection.cs
- TextEditorLists.cs
- Calendar.cs
- GeometryGroup.cs
- SchemaManager.cs
- ProjectionAnalyzer.cs
- DataGridItemAutomationPeer.cs
- DbCommandDefinition.cs
- Brushes.cs
- InheritanceAttribute.cs
- TTSEngineTypes.cs
- SequenceDesigner.cs
- CodeSnippetTypeMember.cs
- FormViewDeletedEventArgs.cs
- StylusPlugin.cs
- WpfGeneratedKnownProperties.cs
- AdRotatorDesigner.cs
- DataProtection.cs
- WizardStepBase.cs
- ButtonChrome.cs
- MultiTrigger.cs
- ChangeInterceptorAttribute.cs
- StorageAssociationTypeMapping.cs
- CustomAttribute.cs
- DataGridViewTextBoxCell.cs
- FlowDocumentView.cs
- ProxySimple.cs
- Propagator.Evaluator.cs
- Misc.cs
- TableParaClient.cs
- QualifierSet.cs
- COM2TypeInfoProcessor.cs
- CDSsyncETWBCLProvider.cs
- ConfigXmlDocument.cs