mirror of
https://github.com/ICDSystems/ICD.Common.Utils.git
synced 2026-04-12 12:07:05 +00:00
feat: Simplifying generic JSON converters
This commit is contained in:
parent
2e0837f5c8
commit
a9a544c433
1 changed files with 4 additions and 1 deletions
|
|
@ -10,7 +10,10 @@ namespace ICD.Common.Utils.Json
|
||||||
/// Creates a new instance of T.
|
/// Creates a new instance of T.
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns></returns>
|
/// <returns></returns>
|
||||||
protected abstract T Instantiate();
|
protected virtual T Instantiate()
|
||||||
|
{
|
||||||
|
return ReflectionUtils.CreateInstance<T>();
|
||||||
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Writes the JSON representation of the object.
|
/// Writes the JSON representation of the object.
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue