コード例 #1
0
 /// <summary>parses json into a section</summary>
 /// <param name="json">json to parse</param>
 /// <returns>section corresponding to the json</returns>
 public static Section Parse(JObject json)
 {
     Section s = new Section();
     s.ID = (ulong?)json["id"];
     s.Name = (string)json["name"];
     s.ParentID = (ulong?)json["parent_id"];
     s.Depth = (uint?)json["depth"];
     s.DisplayOrder = (uint?)json["display_order"];
     s.SuiteID = (ulong?)json["suite_id"];
     return s;
 }
コード例 #2
0
ファイル: Section.cs プロジェクト: zimarrio/testrail-client
 /// <summary>parses json into a section</summary>
 /// <param name="json">json to parse</param>
 /// <returns>section corresponding to the json</returns>
 public static Section Parse(JObject json)
 {
     var s = new Section
     {
         JsonFromResponse = json,
         ID = (ulong?)json["id"],
         Name = (string)json["name"],
         ParentID = (ulong?)json["parent_id"],
         Depth = (uint?)json["depth"],
         DisplayOrder = (uint?)json["display_order"],
         SuiteID = (ulong?)json["suite_id"],
     };
     return s;
 }