CompositeScriptReference 类

定义

表示要合并为单一复合脚本的脚本引用的集合。Represents a collection of script references to combine into a single composite script.

public ref class CompositeScriptReference : System::Web::UI::ScriptReferenceBase
[System.ComponentModel.TypeConverter(typeof(System.Web.UI.EmptyStringExpandableObjectConverter))]
public class CompositeScriptReference : System.Web.UI.ScriptReferenceBase
type CompositeScriptReference = class
    inherit ScriptReferenceBase
Public Class CompositeScriptReference
Inherits ScriptReferenceBase
继承
CompositeScriptReference
属性

注解

CompositeScriptReference实例可以包含的脚本引用数受生成的 URL 的大小限制。The number of script references that a CompositeScriptReference instance can contain is limited by the size of the resulting URL. URL 的长度不能超过1024个字符。The URL cannot be longer than 1024 characters.

如果必须解决此限制, 则有两个选择。If you have to work around this limitation, you have two options. 第一种方法是减少复合脚本包含ScriptReference的对象数。The first option is to reduce the number of ScriptReference objects that the composite script contains. 第二种方法是手动将脚本合并为单个静态文件。The second option is to manually combine the scripts into a single static file. 在这种情况下, 可以将Path属性设置为静态文件的位置。In that case, you can set the Path property to the location of the static file.

构造函数

CompositeScriptReference()

初始化 CompositeScriptReference 类的新实例。Initializes a new instance of the CompositeScriptReference class.

属性

NotifyScriptLoaded

获取或设置一个值,该值指示 ScriptResourceHandler 对象是否在 ECMAScript (JavaScript) 文件末尾自动添加代码来调用 Sys.Application 类的客户端 NotifyScriptLoaded 方法。Gets or sets a value that indicates whether the ScriptResourceHandler object automatically adds code at the end of the ECMAScript (JavaScript) file to call the client NotifyScriptLoaded method of the Sys.Application class.

(继承自 ScriptReferenceBase)
Path

获取或设置引用客户端脚本文件相对于网页的路径。Gets or sets the path of the referenced client script file, relative to the Web page.

(继承自 ScriptReferenceBase)
ResourceUICultures

获取或设置 Path 属性支持的 UI 区域性的逗号分隔列表。Gets or sets a comma-delimited list of UI cultures that are supported by the Path property.

(继承自 ScriptReferenceBase)
ScriptMode

获取或设置要使用的客户端脚本文件的版本(发布版本或调试版本)。Gets or sets the version of the client script file (release or debug) to use.

(继承自 ScriptReferenceBase)
Scripts

获取复合脚本对象中所包含脚本引用的集合。Gets a collection of script references that are contained in the composite script object.

方法

Equals(Object)

确定指定的对象是否等于当前对象。Determines whether the specified object is equal to the current object.

(继承自 Object)
GetHashCode()

用作默认哈希函数。Serves as the default hash function.

(继承自 Object)
GetType()

获取当前实例的 TypeGets the Type of the current instance.

(继承自 Object)
GetUrl(ScriptManager, Boolean)

返回呈现为 src 元素的 script 特性值的 URL。Returns the URL that is rendered as the value of the src attribute of the script element.

IsAjaxFrameworkScript(ScriptManager)

确定复合脚本是否为对 ASP.NET AJAX Framework 脚本的引用。Determines whether the composite script is a reference to an ASP.NET AJAX framework script.

IsFromSystemWebExtensions()

指示复合脚本是否包含对 ASP.NET AJAX 框架脚本的引用。Indicates whether the composite script contains a reference to an ASP.NET AJAX framework script.

MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(继承自 Object)
ToString()

返回一个表示当前对象的 string。Returns a string that represents the current object.

(继承自 Object)

适用于