public bool ProjectExist(int id) { if (ProjectItems == null) { return(false); } return(ProjectItems.Any(x => x.Id == id)); }
/// <summary> /// Checks if the project contains the specified /// </summary> /// <param name="filename"></param> /// <returns></returns> public bool ContainsFile(string filename) { return(ProjectItems.Any(p => p.Filename == filename)); }
/// <summary> /// Checks if the project contains the specified file /// </summary> /// <param name="filename">File name</param> /// <returns>True, if the project contains the specified file.</returns> public bool ContainsFile(string filename) => ProjectItems.Any(p => p.Filename == filename || p.HasChild(filename));