SharpLibEar/Action.cs
changeset 210 83dd86e73448
child 211 96f8b4dc4300
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/SharpLibEar/Action.cs	Sat Jul 23 16:00:04 2016 +0200
     1.3 @@ -0,0 +1,23 @@
     1.4 +//
     1.5 +
     1.6 +
     1.7 +using System;
     1.8 +using System.Runtime.Serialization;
     1.9 +using System.Threading;
    1.10 +
    1.11 +namespace SharpLib.Ear
    1.12 +{
    1.13 +    [DataContract]
    1.14 +    public abstract class Action: IComparable
    1.15 +    {
    1.16 +        public abstract void Execute();
    1.17 +
    1.18 +        public int CompareTo(object obj)
    1.19 +        {
    1.20 +            //Sort by action name
    1.21 +            return Utils.Reflection.GetAttribute<AttributeAction>(GetType()).Name.CompareTo(obj.GetType());            
    1.22 +        }
    1.23 +    }
    1.24 +
    1.25 +
    1.26 +}
    1.27 \ No newline at end of file