public override int CompareTo(DCAnalyticsObject other)
        {
            int result = 0;
            TransitionConditions conditions = other as TransitionConditions;

            if (_conditions.Count > 0 && conditions.Count > 0)
            {
                foreach (var condition in _conditions)
                {
                    var importedCondition = conditions.ByKey(condition.Key);
                    if (importedCondition != null)
                    {
                        if (importedCondition.CompareTo(condition) == 1)
                        {
                            result = 1;
                        }
                        else
                        {
                            result = 0;
                            break;
                        }
                    }
                }
            }
            else
            {
                result = 1;
            }
            return(result);
        }
Example #2
0
 private void Init()
 {
     TransitionConditions = new TransitionConditions(this);
     Name             = "";
     this.ObjectState = ObjectStates.None;
     this.TableName   = "";
 }