mirror of
https://github.com/vrm-c/UniVRM.git
synced 2026-05-10 12:41:57 -05:00
20 lines
452 B
C#
20 lines
452 B
C#
using System.Linq;
|
|
using UnityEngine;
|
|
using System.Collections.Generic;
|
|
|
|
|
|
namespace UniJSON
|
|
{
|
|
public static class JsonParserExtensions
|
|
{
|
|
public static List<T> DeserializeList<T>(this ListTreeNode<JsonValue> jsonList)
|
|
{
|
|
return jsonList.ArrayItems().Select(x => {
|
|
|
|
return JsonUtility.FromJson<T>(new Utf8String(x.Value.Bytes).ToString());
|
|
|
|
}).ToList();
|
|
}
|
|
}
|
|
}
|