Update missed xmldoc/comments

This commit is contained in:
Dean Herbert 2021-11-30 11:56:53 +09:00
parent 2e31f5a338
commit f3f77fa053
2 changed files with 3 additions and 4 deletions

View File

@ -38,10 +38,10 @@ namespace osu.Game.Database
bool IsManaged { get; }
/// <summary>
/// Resolve the value of this instance on the current thread's context.
/// Resolve the value of this instance on the update thread.
/// </summary>
/// <remarks>
/// After resolving the data should not be passed between threads.
/// After resolving, the data should not be passed between threads.
/// </remarks>
T Value { get; }
}

View File

@ -95,8 +95,7 @@ namespace osu.Game.Database
throw new InvalidOperationException($"Can't use {nameof(Value)} on managed objects from non-update threads");
// When using Value, we rely on garbage collection for the realm instance used to retrieve the instance.
// As we are sure that this is on the same thread
// As we are sure that this is on the update thread, there should always be an open and constantly refreshing realm instance to ensure file size growth is a non-issue.
var realm = Realm.GetInstance(data.Realm.Config);
return realm.Find<T>(ID);