java - Get the values of posted array in servlet -


var schedule = [];  var data = {     'user_id' : '12',     'day_of_week' : 'monday',     'when' : 'start',     'modified' : 'true'  }  schedule.push(data); var data = {     'user_id' : '13',     'day_of_week' : 'tuesday',     'when' : 'end',     'modified' : 'false'  } schedule.push(data); // schedule have 2 objects in 

i posting array servlet using jquery ajax post request below .

data :  {'mydata':schedule}, url :"./mycontroller", 

now how can array of objects , literate values? each array object has string, long , boolean type values. how can values iterating?

may can try this

json.getjsonobject("mydata").getstring("your_values"); 

Comments

Popular posts from this blog

css - Which browser returns the correct result for getBoundingClientRect of an SVG element? -

gcc - Calling fftR4() in c from assembly -

.htaccess - Matching full URL in RewriteCond -