Files
Future/Future.Contract/Interfaces/IParameterSetter.cs
2025-08-30 17:19:57 +08:00

31 lines
1.1 KiB
C#
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Controls;
namespace Future.Contract
{
/// <summary>
/// 自定义参数设置器接口,用于设置一个参数的设置器,是对象编辑器的一行
/// </summary>
public interface IParameterSetter
{
/// <summary>
/// 绑定要编辑的自定义参数对象,可重入;注意:每次调用此参数需要重新绑定设置器的视图
/// </summary>
/// <param name="parameter">要进行编辑的参数</param>
void Binding(ParameterDefineAttribute parameter);
/// <summary>
/// 参数设置器对象如果继承此接口的类不是UserControl类型的子类则需要通过此方法返回编辑器视图对象
/// </summary>
UserControl SetterView { get; }
/// <summary>
/// 保存设置
/// </summary>
/// <returns>如果设置失败则返回失败原因</returns>
string SaveConfig();
}
}