4

Very confused. New project, add this code:

import org.json.JSONObject;

JSONObject jsonObject = new JSONObject();
jsonObject.keys();
jsonObject.keySet();

.keys() method resolves as it should.

.keySet() method highlights red with AndroidStudio giving "Cannot resolve method keyset()" error.

If i go to keys() definition, here they both are public and all: http://goloskok.com/u/2015-07-01_16-41-08.jpg

What am I doing wrong?

4

1 回答 1

2

@hide 注释

* @hide.
  */
        public Set<String> keySet() {
            return nameValuePairs.keySet();
        }
于 2015-07-01T06:56:31.507 回答