20231125
This commit is contained in:
@@ -1,6 +1,5 @@
|
||||
using anbs_cp.OsInfo.Classes;
|
||||
|
||||
using Newtonsoft.Json;
|
||||
using anbs_cp.Classes;
|
||||
using anbs_cp.OsInfo.Classes;
|
||||
|
||||
namespace demo;
|
||||
public sealed partial class OsInfoFrm: Form
|
||||
@@ -13,16 +12,16 @@ public sealed partial class OsInfoFrm: Form
|
||||
private void OsInfoFrm_Load (object sender, EventArgs e)
|
||||
{
|
||||
textBox.Text = @"Процессор(ы) | ";
|
||||
textBox.Text += JsonConvert.SerializeObject(OsInfo.Processors);
|
||||
textBox.Text += Serializer.Serialize(OsInfo.Processors);
|
||||
textBox.Text += @"Оперативная память | ";
|
||||
textBox.Text += JsonConvert.SerializeObject(OsInfo.RAM);
|
||||
textBox.Text += Serializer.Serialize(OsInfo.RAM);
|
||||
textBox.Text += @"Видеокарта | ";
|
||||
textBox.Text += JsonConvert.SerializeObject(OsInfo.Videos);
|
||||
textBox.Text += Serializer.Serialize(OsInfo.Videos);
|
||||
textBox.Text += @"Диски | ";
|
||||
textBox.Text += JsonConvert.SerializeObject(OsInfo.Drives);
|
||||
textBox.Text += Serializer.Serialize(OsInfo.Drives);
|
||||
textBox.Text += @"Windows | ";
|
||||
textBox.Text += JsonConvert.SerializeObject(OsInfo.Windows);
|
||||
textBox.Text += Serializer.Serialize(OsInfo.Windows);
|
||||
textBox.Text += @"Net | ";
|
||||
textBox.Text += JsonConvert.SerializeObject(OsInfo.Net);
|
||||
textBox.Text += Serializer.Serialize(OsInfo.Net);
|
||||
}
|
||||
}
|
||||
|
@@ -1,5 +1,4 @@
|
||||
using anbs_cp.Classes;
|
||||
using Newtonsoft.Json;
|
||||
|
||||
namespace demo;
|
||||
public sealed partial class SampleMapperTest: Form
|
||||
@@ -26,7 +25,7 @@ public sealed partial class SampleMapperTest: Form
|
||||
DemoDateTime = default
|
||||
};
|
||||
|
||||
string serialize1 = JsonConvert.SerializeObject(demo2);
|
||||
string serialize1 = Serializer.Serialize(demo2);
|
||||
|
||||
SimpleMapper.MapMode mode = MapModeEdit.SelectedIndex switch
|
||||
{
|
||||
@@ -39,7 +38,7 @@ public sealed partial class SampleMapperTest: Form
|
||||
|
||||
SimpleMapper.MapEx(demo1, ref demo2, mode, new List<string>());
|
||||
|
||||
string serialize2 = JsonConvert.SerializeObject(demo2);
|
||||
string serialize2 = Serializer.Serialize(demo2);
|
||||
|
||||
// ReSharper disable once LocalizableElement
|
||||
ResultArea.Text = $"Класс Demo2 до связывания:\r\n{serialize1}\r\nи после:\r\n{serialize2}";
|
||||
|
Reference in New Issue
Block a user