Code:
/ Dotnetfx_Win7_3.5.1 / Dotnetfx_Win7_3.5.1 / 3.5.1 / DEVDIV / depot / DevDiv / releases / whidbey / NetFXspW7 / 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. // //----------------------------------------------------------------------------- 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.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- IPAddressCollection.cs
- _Win32.cs
- RtfControls.cs
- SafeThreadHandle.cs
- DataSourceCollectionBase.cs
- ExpressionBuilder.cs
- HtmlEmptyTagControlBuilder.cs
- WebPartTransformerAttribute.cs
- BindingCollection.cs
- OperationFormatStyle.cs
- ScriptingSectionGroup.cs
- PageContent.cs
- LocalizableResourceBuilder.cs
- DiscardableAttribute.cs
- WebPartEditorOkVerb.cs
- GeneralTransform.cs
- ResourcePool.cs
- NotifyParentPropertyAttribute.cs
- StyleBamlRecordReader.cs
- ProcessModule.cs
- InfoCardPolicy.cs
- MsmqHostedTransportManager.cs
- TypeForwardedToAttribute.cs
- AudioFileOut.cs
- RelationshipEnd.cs
- ExpressionBinding.cs
- ProviderIncompatibleException.cs
- Regex.cs
- GPRECTF.cs
- FormViewUpdatedEventArgs.cs
- DynamicContractTypeBuilder.cs
- Exception.cs
- TreeNodeCollection.cs
- VisualStateGroup.cs
- BevelBitmapEffect.cs
- Mutex.cs
- DesignerResources.cs
- SchemaElementDecl.cs
- StrongBox.cs
- ColumnPropertiesGroup.cs
- VisualBasicImportReference.cs
- WindowInteropHelper.cs
- CodeIdentifiers.cs
- GeometryModel3D.cs
- ProcessHostConfigUtils.cs
- UnsafeNativeMethodsTablet.cs
- TextServicesContext.cs
- BinaryMessageFormatter.cs
- PrivateFontCollection.cs
- UrlPropertyAttribute.cs
- DataExpression.cs
- PreProcessInputEventArgs.cs
- FontFamilyIdentifier.cs
- TransformerInfo.cs
- WebEventTraceProvider.cs
- SQLString.cs
- Resources.Designer.cs
- ResXResourceReader.cs
- FormViewDeletedEventArgs.cs
- SiteMapProvider.cs
- NativeObjectSecurity.cs
- InputBinder.cs
- EventLogPermissionEntryCollection.cs
- BaseTreeIterator.cs
- FormViewRow.cs
- EntityObject.cs
- X509SecurityTokenAuthenticator.cs
- WebBrowserPermission.cs
- AppSettingsReader.cs
- DefaultObjectSerializer.cs
- LineBreakRecord.cs
- XmlEncodedRawTextWriter.cs
- DataPagerFieldCommandEventArgs.cs
- ConfigurationElement.cs
- OrthographicCamera.cs
- IgnoreFileBuildProvider.cs
- CodeBinaryOperatorExpression.cs
- MetadataUtil.cs
- ImageCodecInfoPrivate.cs
- AttachedPropertyBrowsableWhenAttributePresentAttribute.cs
- VariableQuery.cs
- InputLangChangeRequestEvent.cs
- TextMessageEncodingElement.cs
- BorderSidesEditor.cs
- XpsInterleavingPolicy.cs
- DesignObjectWrapper.cs
- DebugHandleTracker.cs
- HybridObjectCache.cs
- SID.cs
- PathGradientBrush.cs
- ListViewContainer.cs
- CompilerErrorCollection.cs
- activationcontext.cs
- CustomErrorsSection.cs
- Pen.cs
- MobileErrorInfo.cs
- VBCodeProvider.cs
- DynamicRendererThreadManager.cs
- UnknownBitmapEncoder.cs
- OperatingSystemVersionCheck.cs