DeVeLoP

[FlUtTeR] json 문자열 파싱

freecatz 2019. 3. 7. 14:55


1. 서버에서 내려 주는 문자열

{"RESULT":"OK","MESSAGE":"홍길동님 안녕하세요?","NEXTPAGE":"/main"}


2. json 문자열 파싱

    var result = (json.decode(response.body));
print(result['RESULT']);
print(result['MESSAGE']);
print(result['NEXTPAGE']);