init
This commit is contained in:
commit
e124a47765
19374 changed files with 9806149 additions and 0 deletions
|
@ -0,0 +1,13 @@
|
|||
using Newtonsoft.Json;
|
||||
|
||||
namespace Kreta.BusinessLogic.Classes.MobileApi.Naplo.V2.Converter
|
||||
{
|
||||
public static class CustomJsonConverter
|
||||
{
|
||||
public static T DeserializeJsonToObject<T>(string json) where T : class, new()
|
||||
=> !string.IsNullOrWhiteSpace(json) ? JsonConvert.DeserializeObject<T>(json) : null;
|
||||
|
||||
public static string SerializeObjectToJson(object myObject)
|
||||
=> (myObject != null) ? JsonConvert.SerializeObject(myObject) : string.Empty;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue