aboutsummaryrefslogtreecommitdiff
path: root/OpenSubtitlesHandler/Interfaces/IMethodResponse.cs
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSubtitlesHandler/Interfaces/IMethodResponse.cs')
-rw-r--r--OpenSubtitlesHandler/Interfaces/IMethodResponse.cs30
1 files changed, 20 insertions, 10 deletions
diff --git a/OpenSubtitlesHandler/Interfaces/IMethodResponse.cs b/OpenSubtitlesHandler/Interfaces/IMethodResponse.cs
index b8e24f12bd..9c05e357b9 100644
--- a/OpenSubtitlesHandler/Interfaces/IMethodResponse.cs
+++ b/OpenSubtitlesHandler/Interfaces/IMethodResponse.cs
@@ -37,17 +37,17 @@ namespace OpenSubtitlesHandler
protected double seconds;
protected string status;
- protected virtual void LoadAttributes()
+ protected void LoadAttributes()
{
- foreach (Attribute attr in Attribute.GetCustomAttributes(this.GetType()))
- {
- if (attr.GetType() == typeof(MethodResponseDescription))
- {
- this.name = ((MethodResponseDescription)attr).Name;
- this.message = ((MethodResponseDescription)attr).Message;
- break;
- }
- }
+ //foreach (Attribute attr in Attribute.GetCustomAttributes(this.GetType()))
+ //{
+ // if (attr.GetType() == typeof(MethodResponseDescription))
+ // {
+ // this.name = ((MethodResponseDescription)attr).Name;
+ // this.message = ((MethodResponseDescription)attr).Message;
+ // break;
+ // }
+ //}
}
[Description("The name of this response"), Category("MethodResponse")]
@@ -59,4 +59,14 @@ namespace OpenSubtitlesHandler
[Description("The status"), Category("MethodResponse")]
public string Status { get { return status; } set { status = value; } }
}
+
+ public class DescriptionAttribute : Attribute
+ {
+ public DescriptionAttribute(string text) { }
+ }
+
+ public class CategoryAttribute : Attribute
+ {
+ public CategoryAttribute(string text) { }
+ }
}