Automation/Commands/Command.cs
(开头部分) 4KB这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Xml;
using System.Reflection;
namespace ComLib.Automation
{
/// <summary>
/// Base class for an individual command.
/// </summary>
public class Command
{
private Scope _scope;
private Script _script;
/// <summary>
/// Whether or not scope is supported for the command which indicates to the script to enter into a new scope.
/// </summary>
protected bool _isScopeSupported;
/// <summary>
/// Reference id used in scripts to uniquely refer to a specific command.
/// This can be supplied in the script.
/// </summary>
public string RefKey { get; set; }
/// <summary>
/// The script this command is a part of.
/// </summary>
public Script Script { get { return _script; } set { _script = value; } }
/// <summary>
/// Whether or not scope is supported for the command which indicates to the script to enter into a new scope.
/// </summary>
public bool IsScopeSupported { get { return _isScopeSupported; } }
/// <summary>
/// Initialize the scope for variables.
/// </summary>
/// <param name="scope"></param>
internal void InitScope(Scope scope)
{
_scope = scope;
}
/// <summary>
/// Executes the command.
/// </summary>
/// <param name="context"></param>
/// <returns></returns>
public BoolMessageItem Execute(CommandContext context)
{
后面还有 78 行代码,解锁后查看完整代码
24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明
AI 解读
登录后可用,每次 10 积分,解读结果公开显示在下面。
还没有人解读过这个文件。
