예제 #1
0
        bool BasesIncludesSelf(ArtefactBase artefact)
        {
            foreach (var @base in artefact.Bases)
            {
                if (@base.ProperName.Equals(artefact.ProperName))
                {
                    return true;
                }
            }

            return false;
        }
예제 #2
0
        bool ArtefactDerivesFromAnEnclosingScopeArtefact(ArtefactBase artefact, Func<IEnumerable<ArtefactBase>> scopeSelector)
        {
            foreach (var baseArtefact in artefact.Bases)
            {
                if (ReferenceIsInEnclosingScope(baseArtefact, scopeSelector)) return true;
            }

            return false;
        }