Last change
on this file since 17511 was
17406,
checked in by dpiringe, 5 years ago
|
#3026
- added interfaces IJsonItem and IJsonItemValidator
- replaced every reference JsonItem with IJsonItem
|
File size:
1.0 KB
|
Rev | Line | |
---|
[17263] | 1 | using System;
|
---|
| 2 | using System.Collections.Generic;
|
---|
| 3 | using System.Linq;
|
---|
| 4 | using System.Text;
|
---|
| 5 | using System.Threading.Tasks;
|
---|
| 6 | using HeuristicLab.Core;
|
---|
| 7 | using Newtonsoft.Json.Linq;
|
---|
| 8 |
|
---|
[17284] | 9 | namespace HeuristicLab.JsonInterface {
|
---|
[17281] | 10 | public interface IJsonItemConverter {
|
---|
[17280] | 11 | /// <summary>
|
---|
[17353] | 12 | /// Injects the saved infos from the JsonItem into the IItem.
|
---|
| 13 | /// (Sets the necessary values.)
|
---|
| 14 | /// </summary>
|
---|
| 15 | /// <param name="item">The IItem which get the data injected.</param>
|
---|
| 16 | /// <param name="data">The JsonItem with the saved values.</param>
|
---|
[17406] | 17 | void Inject(IItem item, IJsonItem data, IJsonItemConverter root);
|
---|
[17353] | 18 |
|
---|
| 19 | /// <summary>
|
---|
[17283] | 20 | /// Extracts all infos out of an IItem to create a JsonItem.
|
---|
[17280] | 21 | /// (For template generation.)
|
---|
| 22 | /// </summary>
|
---|
| 23 | /// <param name="value">The IItem to extract infos.</param>
|
---|
[17283] | 24 | /// <returns>JsonItem with infos to reinitialise the IItem.</returns>
|
---|
[17406] | 25 | IJsonItem Extract(IItem value, IJsonItemConverter root);
|
---|
[17394] | 26 |
|
---|
| 27 | Type ConvertableType { get; }
|
---|
| 28 | int Priority { get; }
|
---|
[17263] | 29 | }
|
---|
| 30 | }
|
---|
[17266] | 31 |
|
---|
Note: See
TracBrowser
for help on using the repository browser.