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
- XmlAttributeAttribute.cs
- Html32TextWriter.cs
- XmlTextReaderImpl.cs
- ProtocolsSection.cs
- Ipv6Element.cs
- GlyphRun.cs
- PrePostDescendentsWalker.cs
- ZipIOLocalFileBlock.cs
- BidPrivateBase.cs
- Stylesheet.cs
- TimeSpanMinutesOrInfiniteConverter.cs
- SqlBinder.cs
- Function.cs
- login.cs
- Walker.cs
- ControlBuilderAttribute.cs
- DirectoryGroupQuery.cs
- DesignerHelpers.cs
- InvalidWMPVersionException.cs
- UdpMessageProperty.cs
- SQlBooleanStorage.cs
- TypeSource.cs
- WebUtil.cs
- SQLMembershipProvider.cs
- querybuilder.cs
- BehaviorEditorPart.cs
- ConnectionDemuxer.cs
- BitSet.cs
- LinearQuaternionKeyFrame.cs
- RuntimeResourceSet.cs
- IntranetCredentialPolicy.cs
- CompoundFileDeflateTransform.cs
- WmiEventSink.cs
- ECDiffieHellmanPublicKey.cs
- Nullable.cs
- BufferedGraphics.cs
- Exceptions.cs
- ReferenceAssemblyAttribute.cs
- NotifyCollectionChangedEventArgs.cs
- DataGridViewButtonColumn.cs
- ACL.cs
- XPathSelfQuery.cs
- LogAppendAsyncResult.cs
- CssTextWriter.cs
- ReadOnlyDataSource.cs
- RealizationDrawingContextWalker.cs
- ProxyWebPartManager.cs
- XomlCompilerHelpers.cs
- WindowsSysHeader.cs
- EventLogEntry.cs
- ErrorRuntimeConfig.cs
- Message.cs
- SHA384Managed.cs
- AdPostCacheSubstitution.cs
- FlowLayoutSettings.cs
- WrappedKeySecurityTokenParameters.cs
- QilStrConcatenator.cs
- DocumentViewerBase.cs
- StylusButton.cs
- ContentPosition.cs
- XmlWrappingReader.cs
- StdRegProviderWrapper.cs
- HttpRuntime.cs
- TextEditorLists.cs
- LogSwitch.cs
- AuthenticationConfig.cs
- TableLayoutStyle.cs
- TrackingCondition.cs
- odbcmetadatacolumnnames.cs
- SegmentInfo.cs
- ClientConfigPaths.cs
- XmlSchemaAll.cs
- SettingsPropertyWrongTypeException.cs
- Themes.cs
- TemplateInstanceAttribute.cs
- _emptywebproxy.cs
- ObjectStateManager.cs
- SecurityResources.cs
- IssuanceLicense.cs
- ItemList.cs
- NativeMethodsOther.cs
- SmtpReplyReader.cs
- Stacktrace.cs
- PathParser.cs
- CodeMemberEvent.cs
- BamlStream.cs
- CodeNamespaceImportCollection.cs
- XmlChildNodes.cs
- Int32Rect.cs
- SiteMapProvider.cs
- arc.cs
- ConfigurationPropertyCollection.cs
- AddingNewEventArgs.cs
- SqlDataSourceDesigner.cs
- SvcMapFile.cs
- UnicastIPAddressInformationCollection.cs
- ConfigDefinitionUpdates.cs
- GridViewRowPresenter.cs
- SourceElementsCollection.cs
- CaseInsensitiveComparer.cs