implement IDisposable for Document so we can do cool things like (using Document.Load()...)
This commit is contained in:
parent
477ebaed5a
commit
28bb5da3cc
@ -30,7 +30,7 @@ namespace UniversalEditor
|
||||
/// to, the DataFormat determines HOW the data is written, and the ObjectModel contains the actual data in a format-
|
||||
/// agnostic representation.
|
||||
/// </summary>
|
||||
public class Document
|
||||
public class Document : IDisposable
|
||||
{
|
||||
/// <summary>
|
||||
/// The <see cref="Accessor" /> which determines where the data is read from.
|
||||
@ -55,6 +55,11 @@ namespace UniversalEditor
|
||||
/// </summary>
|
||||
public ObjectModel ObjectModel { get { return mvarObjectModel; } set { mvarObjectModel = value; } }
|
||||
|
||||
public void Dispose()
|
||||
{
|
||||
Close();
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Reads data into the current <see cref="ObjectModel" /> from the <see cref="Accessor" /> using the
|
||||
/// current <see cref="InputDataFormat" />.
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user