requiredscriptattribute.cs
来自「AJAX 应用 实现页面的无刷新」· CS 代码 · 共 59 行
CS
59 行
// (c) Copyright Microsoft Corporation.
// This source is subject to the Microsoft Permissive License.
// See http://www.microsoft.com/resources/sharedsource/licensingbasics/sharedsourcelicenses.mspx.
// All other rights reserved.
using System;
using System.ComponentModel;
using System.Collections.Generic;
using System.Text;
namespace AjaxControlToolkit
{
[AttributeUsage(AttributeTargets.Class, AllowMultiple=true)]
public sealed class RequiredScriptAttribute : Attribute
{
private int _order;
private Type _extenderType;
private string _scriptName;
public Type ExtenderType
{
get { return _extenderType; }
}
public string ScriptName
{
get { return _scriptName; }
}
public int LoadOrder
{
get { return _order; }
}
public RequiredScriptAttribute()
{
}
public RequiredScriptAttribute(string scriptName)
{
_scriptName = scriptName;
}
public RequiredScriptAttribute(Type extenderType): this(extenderType, 0) {
}
public RequiredScriptAttribute(Type extenderType, int loadOrder)
{
_extenderType = extenderType;
_order = loadOrder;
}
public override bool IsDefaultAttribute()
{
return _extenderType == null;
}
}
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?