internal MemberCell(CellSet ACellSet, CellsetMember M)
        {
            CellSet = ACellSet;
            Model   = M;
#if DEBUG
            if (M != null && M.DisplayName != null && M.DisplayName.Contains("Ken"))
            {
                var cc = M.GetHashCode();
            }
#endif
        }
示例#2
0
        internal DrillAction(Level level, CellsetMember member)
            : this()
        {
            ParentLevel = member.FMember.Level;
            Level       = level;
            var cur = member;

            while (cur != null)
            {
                if (cur.FMember != null)
                {
                    Members.AddLast(cur.FMember);
                }
                cur = cur.FParent;
            }
        }
示例#3
0
        //internal static PossibleDrillActions GetDrilledAction(Member m, HashSet<DrillAction> actions)
        //{
        //    return GetDrilledAction(m, actions, null);
        //}

        internal static PossibleDrillActions GetDrilledAction(Member m, HashSet <DrillAction> actions, CellsetMember ASM)
        {
            if (m.FMemberType == MemberType.mtGroup && m.Children.Count == 0)
            {
                return(PossibleDrillActions.esNone);
            }

            foreach (var a in actions)
            {
                if (ASM == null)
                {
                    if (a.Members.Count > 0 && a.Members.First() == m)
                    {
                        return(a.Method);
                    }

                    if (a.ParentLevel == m.Level && a.DrillUps != null && !a.DrillUps.Contains(m))
                    {
                        return(a.Method);
                    }
                }
                else
                {
                    if (ASM.IsThisDrillAction(a))
                    {
                        return(a.Method);
                    }

                    if (ASM.FMember.Children.Count == 0)
                    {
                        if (a.ParentLevel == m.Level &&
                            a.DrillUps != null &&
                            !a.DrillUps.Contains(m) &&
                            a.IsAllDrilled)
                        {
                            return(a.Method);
                        }
                    }
                }
            }

            return(PossibleDrillActions.esNone);
        }