KnowledgeBase.KB.RemovePropertyPerspective C# (CSharp) Method

RemovePropertyPerspective() private method

private RemovePropertyPerspective ( Name property, List ToMList ) : Name
property Name
ToMList List
return Name
        private Name RemovePropertyPerspective(Name property, List<Name> ToMList)
        {
            var self = ToMList.Last();
            if (self.IsUniversal && property.HasSelf())
                throw new InvalidOperationException($"Cannot evaluate a property containing SELF in the Universal context of the {nameof(KB)}");

            if (self == Name.SELF_SYMBOL)
                self = Perspective;

            var p = property.RemovePerspective(self);
            return p;
        }