Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / DEVDIV / depot / DevDiv / releases / whidbey / QFE / ndp / fx / src / xsp / System / Web / UI / ViewStateModeByIdAttribute.cs / 3 / ViewStateModeByIdAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.Web.UI { using System; using System.Collections; using System.Collections.Generic; using System.ComponentModel; using System.Security.Permissions; [AspNetHostingPermission(SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)] [AttributeUsage(AttributeTargets.Class)] public sealed class ViewStateModeByIdAttribute : Attribute { static Hashtable _viewStateIdTypes = Hashtable.Synchronized(new Hashtable()); public ViewStateModeByIdAttribute() { } internal static bool IsEnabled(Type type) { if (!_viewStateIdTypes.ContainsKey(type)) { System.ComponentModel.AttributeCollection attrs = TypeDescriptor.GetAttributes(type); ViewStateModeByIdAttribute attr = (ViewStateModeByIdAttribute)attrs[typeof(ViewStateModeByIdAttribute)]; _viewStateIdTypes[type] = (attr != null); } return (bool)_viewStateIdTypes[type]; } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // Copyright (c) Microsoft Corporation. All rights reserved. //------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- /* */ namespace System.Web.UI { using System; using System.Collections; using System.Collections.Generic; using System.ComponentModel; using System.Security.Permissions; [AspNetHostingPermission(SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)] [AttributeUsage(AttributeTargets.Class)] public sealed class ViewStateModeByIdAttribute : Attribute { static Hashtable _viewStateIdTypes = Hashtable.Synchronized(new Hashtable()); public ViewStateModeByIdAttribute() { } internal static bool IsEnabled(Type type) { if (!_viewStateIdTypes.ContainsKey(type)) { System.ComponentModel.AttributeCollection attrs = TypeDescriptor.GetAttributes(type); ViewStateModeByIdAttribute attr = (ViewStateModeByIdAttribute)attrs[typeof(ViewStateModeByIdAttribute)]; _viewStateIdTypes[type] = (attr != null); } return (bool)_viewStateIdTypes[type]; } } } // 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
- SerializationEventsCache.cs
- XmlSchemaSimpleContentExtension.cs
- MILUtilities.cs
- ImmComposition.cs
- DefaultProxySection.cs
- MeshGeometry3D.cs
- SymbolDocumentInfo.cs
- WebPartCatalogCloseVerb.cs
- DataGridTextBox.cs
- AsyncStreamReader.cs
- ConfigsHelper.cs
- Message.cs
- MDIWindowDialog.cs
- SmtpLoginAuthenticationModule.cs
- MarkupExtensionReturnTypeAttribute.cs
- TimeSpanValidatorAttribute.cs
- HttpCachePolicy.cs
- Typeface.cs
- SymbolEqualComparer.cs
- DiagnosticTraceSource.cs
- XmlSerializerNamespaces.cs
- DataColumnPropertyDescriptor.cs
- SBCSCodePageEncoding.cs
- DataGridViewCellMouseEventArgs.cs
- TypeConstant.cs
- WsdlImporterElement.cs
- SerializationStore.cs
- ReliableOutputConnection.cs
- DataControlExtensions.cs
- ReplyAdapterChannelListener.cs
- DbProviderFactoriesConfigurationHandler.cs
- FilePrompt.cs
- ObjectDataSource.cs
- _UriTypeConverter.cs
- PropertyDescriptorGridEntry.cs
- TypeSystemHelpers.cs
- AccessKeyManager.cs
- ScriptingAuthenticationServiceSection.cs
- MissingSatelliteAssemblyException.cs
- DataProtection.cs
- SelfSignedCertificate.cs
- ImageBrush.cs
- sqlinternaltransaction.cs
- PolyBezierSegment.cs
- SqlXml.cs
- GeneralTransform3DGroup.cs
- BufferAllocator.cs
- TextParaClient.cs
- BrowserCapabilitiesFactoryBase.cs
- Descriptor.cs
- DataTrigger.cs
- ISAPIRuntime.cs
- Single.cs
- OrderedDictionary.cs
- PropertyNames.cs
- XPathNodeInfoAtom.cs
- NamespaceDecl.cs
- KeyNotFoundException.cs
- OutputScope.cs
- EnvironmentPermission.cs
- OleDbRowUpdatedEvent.cs
- SecurityException.cs
- LineBreakRecord.cs
- DateTimeOffsetStorage.cs
- WebPartConnectionsCancelVerb.cs
- xmlglyphRunInfo.cs
- Group.cs
- ButtonPopupAdapter.cs
- Metafile.cs
- LogConverter.cs
- XmlDomTextWriter.cs
- TableLayoutStyleCollection.cs
- DataGridViewDesigner.cs
- DecimalConverter.cs
- ChannelTokenTypeConverter.cs
- VirtualDirectoryMappingCollection.cs
- ListBindingConverter.cs
- ItemsPresenter.cs
- ModelProperty.cs
- ServiceCredentialsSecurityTokenManager.cs
- BaseServiceProvider.cs
- DesignerWithHeader.cs
- GridViewSortEventArgs.cs
- TextWriterEngine.cs
- MemberMaps.cs
- DoubleLinkList.cs
- SequentialWorkflowHeaderFooter.cs
- Misc.cs
- ColorTranslator.cs
- XmlHierarchyData.cs
- XmlReflectionMember.cs
- ManifestResourceInfo.cs
- SqlDataSourceCommandEventArgs.cs
- VerticalAlignConverter.cs
- RegexBoyerMoore.cs
- OrderedDictionary.cs
- ConnectionPointGlyph.cs
- InfoCardRSAPKCS1KeyExchangeDeformatter.cs
- ToolboxItem.cs
- OdbcEnvironment.cs