I am using a web API and for example it returns:
access_token=aZDi8ZlmDL34YyxCQt0jXdsRl9Kcinye8r8ilwqCOe3-OII2B96XblSyK7urG4DvPYc&expires_in=1396212623&is_voice_enrolled=false&device_id=3
So, I need to split up this single string to Key/Value pairs.
access_token:aZDi8ZlmDL34YyxCQt0jXdsRl9Kcinye8r8ilwqCOe3-OII2B96XblSyK7urG4DvPYc
expires_in:1396212623
is_voice_enrolled:false
device_id:3
What is the best way to convert this? Should I split by the &
and then split again by the =
sign?
Thanks!