我有两个这样定义的自定义属性:
internal class SchemaAttribute : Attribute {
internal SchemaAttribute(string schema) {
Schema = schema;
}
internal string Schema { get; private set; }
}
internal class AttributeAttribute : Attribute {
internal AttributeAttribute(string attribute) {
Attribute = attribute;
}
internal string Attribute { get; private set; }
}
我想将 SchemaAttribute 限制为类,将 AttributeAttribute 限制为属性。
这是可行的吗?