Code:
/ FXUpdate3074 / FXUpdate3074 / 1.1 / DEVDIV / depot / DevDiv / releases / whidbey / QFE / ndp / fx / src / xsp / System / Web / UI / WebResourceAttribute.cs / 1 / WebResourceAttribute.cs
//------------------------------------------------------------------------------ //// Copyright (c) Microsoft Corporation. All rights reserved. // //----------------------------------------------------------------------------- namespace System.Web.UI { using System; using System.ComponentModel; using System.Security.Permissions; using System.Web.Util; [AttributeUsage(AttributeTargets.Assembly, AllowMultiple=true)] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class WebResourceAttribute : Attribute { private string _contentType; private bool _performSubstitution; private string _webResource; public WebResourceAttribute(string webResource, string contentType) { if (String.IsNullOrEmpty(webResource)) { throw ExceptionUtil.ParameterNullOrEmpty("webResource"); } if (String.IsNullOrEmpty(contentType)) { throw ExceptionUtil.ParameterNullOrEmpty("contentType"); } _contentType = contentType; _webResource = webResource; _performSubstitution = false; } public string ContentType { get { return _contentType; } } public bool PerformSubstitution { get { return _performSubstitution; } set { _performSubstitution = value; } } public string WebResource { get { return _webResource; } } } } // 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.ComponentModel; using System.Security.Permissions; using System.Web.Util; [AttributeUsage(AttributeTargets.Assembly, AllowMultiple=true)] [AspNetHostingPermission(SecurityAction.LinkDemand, Level=AspNetHostingPermissionLevel.Minimal)] public sealed class WebResourceAttribute : Attribute { private string _contentType; private bool _performSubstitution; private string _webResource; public WebResourceAttribute(string webResource, string contentType) { if (String.IsNullOrEmpty(webResource)) { throw ExceptionUtil.ParameterNullOrEmpty("webResource"); } if (String.IsNullOrEmpty(contentType)) { throw ExceptionUtil.ParameterNullOrEmpty("contentType"); } _contentType = contentType; _webResource = webResource; _performSubstitution = false; } public string ContentType { get { return _contentType; } } public bool PerformSubstitution { get { return _performSubstitution; } set { _performSubstitution = value; } } public string WebResource { get { return _webResource; } } } } // 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
- TraceLevelStore.cs
- XmlReaderSettings.cs
- KerberosTicketHashIdentifierClause.cs
- _BaseOverlappedAsyncResult.cs
- EntityDataSourceSelectedEventArgs.cs
- IIS7WorkerRequest.cs
- DataGridViewComboBoxColumn.cs
- NumericPagerField.cs
- EntityStoreSchemaFilterEntry.cs
- SimpleWebHandlerParser.cs
- TraceInternal.cs
- DataContractSerializerElement.cs
- TableItemProviderWrapper.cs
- ChangePassword.cs
- httpstaticobjectscollection.cs
- DefaultTraceListener.cs
- MissingMemberException.cs
- EventDrivenDesigner.cs
- CharAnimationBase.cs
- ListenerAdaptersInstallComponent.cs
- ParameterBuilder.cs
- GlobalProxySelection.cs
- ConfigurationElementCollection.cs
- WeakHashtable.cs
- PeerPresenceInfo.cs
- DataControlPagerLinkButton.cs
- StructuredTypeEmitter.cs
- _WebProxyDataBuilder.cs
- WsatAdminException.cs
- X509CertificateCollection.cs
- InternalsVisibleToAttribute.cs
- CachedTypeface.cs
- BrowserDefinitionCollection.cs
- NetCodeGroup.cs
- StreamSecurityUpgradeProvider.cs
- GenericPrincipal.cs
- TextSelectionProcessor.cs
- GradientStopCollection.cs
- BasicExpandProvider.cs
- CompilerGeneratedAttribute.cs
- PageAdapter.cs
- SafeLocalMemHandle.cs
- Vector3DAnimationBase.cs
- BrowsableAttribute.cs
- SecurityHelper.cs
- BevelBitmapEffect.cs
- ReferentialConstraint.cs
- TypeDelegator.cs
- NotifyIcon.cs
- diagnosticsswitches.cs
- ToolbarAUtomationPeer.cs
- CultureSpecificStringDictionary.cs
- OpCodes.cs
- ListenerElementsCollection.cs
- SmtpMail.cs
- XmlSchemaSimpleTypeUnion.cs
- UniqueContractNameValidationBehavior.cs
- ScriptRef.cs
- ResourcePermissionBaseEntry.cs
- ReadOnlyObservableCollection.cs
- XmlSchemaIdentityConstraint.cs
- XmlSchemaNotation.cs
- RuleSettings.cs
- GridViewRowPresenterBase.cs
- NameTable.cs
- DesignTableCollection.cs
- ClientSponsor.cs
- SerializationStore.cs
- AbandonedMutexException.cs
- OdbcConnectionString.cs
- PerformanceCountersElement.cs
- TraceSource.cs
- HttpRequestCacheValidator.cs
- InvalidOperationException.cs
- KerberosReceiverSecurityToken.cs
- ParsedAttributeCollection.cs
- XPathCompileException.cs
- X509SecurityTokenProvider.cs
- SoapEnumAttribute.cs
- CancellationHandlerDesigner.cs
- NetworkInterface.cs
- CollectionChangeEventArgs.cs
- UmAlQuraCalendar.cs
- ConfigXmlElement.cs
- DataGridParentRows.cs
- TypeDescriptionProviderAttribute.cs
- SQLInt64Storage.cs
- RepeaterCommandEventArgs.cs
- Hashtable.cs
- WebResourceAttribute.cs
- DictionaryManager.cs
- TreeViewImageKeyConverter.cs
- SimpleType.cs
- DataGridSortCommandEventArgs.cs
- ImmutableCollection.cs
- QilReference.cs
- WebPartTracker.cs
- DataGridViewTopLeftHeaderCell.cs
- PlatformCulture.cs
- SqlConnectionStringBuilder.cs