/// <summary> /// Returns whether the calling Entity inherits from another Entity that implements IWindow /// </summary> /// <param name="instance">The calling Entity</param> /// <returns>Whether the implementation is found in a base Entity.</returns> public static bool GetInheritsFromIWindow(this EntitySave instance) { if (string.IsNullOrEmpty(instance.BaseEntity)) { return(false); } else { EntitySave entitySave = ObjectFinder.Self.GetEntitySave(instance.BaseEntity); return(entitySave != null && (entitySave.ImplementsIWindow || entitySave.GetInheritsFromIWindow())); } }
public static bool GetImplementsIWindowRecursively(this EntitySave instance) { return(instance.ImplementsIWindow || instance.GetInheritsFromIWindow()); }