JsonGet

 

JsonGet ÇÔ¼ö´Â JSON °´Ã¼¿¡¼­ ƯÁ¤ ۰ªÀ» °¡Á®¿Â´Ù.

 

string @JsonGet(string objectId, string key);

 

ÇÔ¼öÀÎÀÚ

string objectId   : ´ë»ó JSON °´Ã¼ ID

string key         : °¡Á®¿Ã Ű À̸§

  

¹Ýȯ °ª

¼º°ø ½Ã JSON °´Ã¼ ID

½ÇÆÐ ½Ã ºó ¹®ÀÚ¿­

 

 

¿¹Á¦ 1)

string jsonObject = @JsonStructNew("{}");
@JsonSet(jsonObject, "user", "°ü¸®ÀÚ", "string");
@JsonSet(jsonObject, "level", 5, "int");

// "user" ŰÀÇ °ªÀ» °¡Á®¿È
string userKey = @JsonGet(jsonObject, "user");
string userValue = @JsonToString(userKey);
// °á°ú: "°ü¸®ÀÚ"

 

 

¿¹Á¦ 2)

string personId = @JsonStructNew("{}");
@JsonSet(personId, "name", "È«±æµ¿", "string");

string addressId = @JsonStructNew("{}");
@JsonSet(addressId, "city", "¼­¿ï", "string");
@JsonSet(personId, "address", addressId, "");

// address °´Ã¼ °¡Á®¿À±â
string extractedAddressId = @JsonGet(personId, "address");
// ÃßÃâµÈ °´Ã¼¿¡¼­ city °ª °¡Á®¿À±â
string cityValue = @JsonGetValue(extractedAddressId, "city");

 

¹öÀüÁ¤º¸

ÃÖÃÊÁö¿ø: 10.3.6.25

 

°ü·Ã Ç׸ñ)

JsonStructNew

JsonAppend

JsonSet

JsonToString

JsonClear

JsonGet

JsonFromString

JsonSetValue

JsonGetValue

JsonClearAll

JsonStringGetValue

JsonStringSetValue

JsonTemplateLoad

JsonTemplateReplacePlaceholder

JsonTemplateReplaceDone

JsonTemplateReplaceMissing

JsonTemplateTagSet