Code:
/ 4.0 / 4.0 / untmp / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / cdf / src / NetFx40 / System.ServiceModel.Activities / System / ServiceModel / Activities / Configuration / ChannelSettingsElement.cs / 1305376 / ChannelSettingsElement.cs
//------------------------------------------------------------------------------ // Copyright (c) Microsoft Corporation. All rights reserved. //----------------------------------------------------------------------------- namespace System.ServiceModel.Activities.Configuration { using System.Runtime; using System.Configuration; using System.ComponentModel; using System.Globalization; using System.ServiceModel.Configuration; using System.ServiceModel.Activities.Description; public sealed class ChannelSettingsElement : ConfigurationElement { ConfigurationPropertyCollection properties; public ChannelSettingsElement() { } [ConfigurationProperty(ConfigurationStrings.IdleTimeout, DefaultValue = ChannelCacheDefaults.DefaultIdleTimeoutString)] [TypeConverter(typeof(TimeSpanOrInfiniteConverter))] [ServiceModelTimeSpanValidator(MinValueString = ConfigurationStrings.TimeSpanZero)] public TimeSpan IdleTimeout { get { return (TimeSpan)base[ConfigurationStrings.IdleTimeout]; } set { base[ConfigurationStrings.IdleTimeout] = value; } } [ConfigurationProperty(ConfigurationStrings.LeaseTimeout, DefaultValue = ChannelCacheDefaults.DefaultChannelLeaseTimeoutString)] [TypeConverter(typeof(TimeSpanOrInfiniteConverter))] [ServiceModelTimeSpanValidator(MinValueString = ConfigurationStrings.TimeSpanZero)] public TimeSpan LeaseTimeout { get { return (TimeSpan)base[ConfigurationStrings.LeaseTimeout]; } set { base[ConfigurationStrings.LeaseTimeout] = value; } } [ConfigurationProperty(ConfigurationStrings.MaxItemsInCache, DefaultValue = ChannelCacheDefaults.DefaultMaxItemsPerCacheString)] [IntegerValidator(MinValue = 0)] public int MaxItemsInCache { get { return (int)base[ConfigurationStrings.MaxItemsInCache]; } set { base[ConfigurationStrings.MaxItemsInCache] = value; } } protected override ConfigurationPropertyCollection Properties { get { if (this.properties == null) { ConfigurationPropertyCollection properties = new ConfigurationPropertyCollection(); properties.Add(new ConfigurationProperty(ConfigurationStrings.MaxItemsInCache, typeof(System.Int32), ChannelCacheDefaults.DefaultMaxItemsPerCache, null, new System.Configuration.IntegerValidator(1, 2147483647, false), System.Configuration.ConfigurationPropertyOptions.None)); properties.Add(new ConfigurationProperty(ConfigurationStrings.IdleTimeout, typeof(System.TimeSpan), ChannelCacheDefaults.DefaultIdleTimeout, new System.Runtime.TimeSpanOrInfiniteConverter(), new System.Runtime.TimeSpanOrInfiniteValidator(System.TimeSpan.Parse("00:00:00", CultureInfo.InvariantCulture), System.TimeSpan.Parse("24.20:31:23.6470000", CultureInfo.InvariantCulture)), System.Configuration.ConfigurationPropertyOptions.None)); properties.Add(new ConfigurationProperty(ConfigurationStrings.LeaseTimeout, typeof(System.TimeSpan), ChannelCacheDefaults.DefaultFactoryLeaseTimeoutString, new System.Runtime.TimeSpanOrInfiniteConverter(), new System.Runtime.TimeSpanOrInfiniteValidator(System.TimeSpan.Parse("00:00:00", CultureInfo.InvariantCulture), System.TimeSpan.Parse("24.20:31:23.6470000", CultureInfo.InvariantCulture)), System.Configuration.ConfigurationPropertyOptions.None)); this.properties = properties; } return this.properties; } } } } // 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
- OrCondition.cs
- HostExecutionContextManager.cs
- MSAAWinEventWrap.cs
- ResolveNameEventArgs.cs
- Menu.cs
- SmiRequestExecutor.cs
- AddInToken.cs
- BooleanProjectedSlot.cs
- ScriptResourceMapping.cs
- Site.cs
- WebPartMenu.cs
- FloaterBaseParaClient.cs
- FilterElement.cs
- FillErrorEventArgs.cs
- StringReader.cs
- SerialErrors.cs
- DataSourceControlBuilder.cs
- ProcessProtocolHandler.cs
- UriSchemeKeyedCollection.cs
- CheckBox.cs
- Listbox.cs
- ChildTable.cs
- WriterOutput.cs
- UserInitiatedRoutedEventPermission.cs
- HostedTransportConfigurationManager.cs
- LineSegment.cs
- SchemaTypeEmitter.cs
- ToolStripProgressBar.cs
- DiagnosticsConfigurationHandler.cs
- __Filters.cs
- DataContext.cs
- HMACSHA384.cs
- HtmlShim.cs
- InstanceStore.cs
- InputChannelBinder.cs
- DataGridViewCellStyle.cs
- SplineKeyFrames.cs
- Stylesheet.cs
- XmlTextWriter.cs
- UpdateException.cs
- Console.cs
- InvalidCommandTreeException.cs
- InvalidCommandTreeException.cs
- MonikerSyntaxException.cs
- _NetRes.cs
- DataGridViewButtonColumn.cs
- UnsafeNativeMethods.cs
- WindowsListViewItem.cs
- XmlUnspecifiedAttribute.cs
- NativeMethods.cs
- IFormattable.cs
- RectangleHotSpot.cs
- DeploymentSectionCache.cs
- InstanceHandle.cs
- DoubleLinkList.cs
- WebExceptionStatus.cs
- StreamUpdate.cs
- ExclusiveCanonicalizationTransform.cs
- PermissionAttributes.cs
- VBCodeProvider.cs
- TemplateContentLoader.cs
- ByteRangeDownloader.cs
- DataQuery.cs
- FactoryId.cs
- Array.cs
- WindowsGrip.cs
- AutoSizeToolBoxItem.cs
- QilNode.cs
- RNGCryptoServiceProvider.cs
- SqlHelper.cs
- SqlBooleanMismatchVisitor.cs
- XmlBoundElement.cs
- XmlCustomFormatter.cs
- WindowsProgressbar.cs
- OdbcConnectionFactory.cs
- DataGridViewLinkColumn.cs
- UIElement3D.cs
- ColumnHeaderConverter.cs
- SessionPageStatePersister.cs
- WorkflowService.cs
- columnmapkeybuilder.cs
- _DigestClient.cs
- DataKeyArray.cs
- SQLString.cs
- XmlBinaryReaderSession.cs
- ImageAutomationPeer.cs
- DesignerWidgets.cs
- SqlBuffer.cs
- TableAdapterManagerGenerator.cs
- HtmlShimManager.cs
- EventSinkActivityDesigner.cs
- Bits.cs
- ToolBarTray.cs
- ObjectSecurity.cs
- KeyBinding.cs
- StorageScalarPropertyMapping.cs
- TraceHandler.cs
- EnvelopedPkcs7.cs
- DefaultMergeHelper.cs
- BuildResult.cs