Beispiel #1
0
        public override string Handle(IFamilyMember source, IFamilyMember target)
        {
            var isEx = source.IsDivorcedFrom(target);

            if (target.GetFactValue <int>(FactType.YPosition) == 0 && !source.IsMarriedTo(target) && !isEx)
            {
                return(RelationshipType.Sibling.ToString());
            }
            else
            {
                return(successor.Handle(source, target));
            }
        }
Beispiel #2
0
        public override string Handle(IFamilyMember source, IFamilyMember target)
        {
            var isEx = source.IsDivorcedFrom(target);

            if (target.GetFactValue <int>(FactType.YPosition) == 0 && (source.IsMarriedTo(target) || isEx))
            {
                return(string.Format("{0}{1}",
                                     isEx ? (RelationshipModifier.Ex.ToString() + "-") : string.Empty,
                                     RelationshipType.Spouse.ToString()));
            }
            else
            {
                return(successor.Handle(source, target));
            }
        }