Access database recursively.

This commit is contained in:
Huo Yaoyuan
2017-05-06 15:37:53 +08:00
parent 146d57953d
commit 767cfaaac3
6 changed files with 23 additions and 35 deletions

View File

@ -48,9 +48,9 @@ namespace osu.Game.Database
return Connection.Table<T>();
}
public T GetWithChildren<T>(object id) where T : class
public T GetWithChildren<T>(object id, bool recursive = false) where T : class
{
return Connection.GetWithChildren<T>(id);
return Connection.GetWithChildren<T>(id, recursive);
}
public List<T> GetAllWithChildren<T>(Expression<Func<T, bool>> filter = null, bool recursive = true)