I am working with Datatables 1.10.10. As the size of the dataset is getting large, I find a need to begin using the serverside API provided by Datatables. I have done this before in PHP, but the problem I am having this time is that I need to handle this with Java 8 (in Struts 2 to be more precise).
The API used by DataTables to request the data from the backend is sending query parameters in this format (note some parameters are empty, but they are sent anyway):
draw=1
columns[0][data]=name
columns[0][name]=
columns[0][searchable]=true
columns[0][orderable]=true
columns[0][search][value]=
columns[0][search][regex]=false
columns[1][data]=binType
columns[1][name]=
columns[1][searchable]=true
columns[1][orderable]=true
columns[1][search][value]=
columns[1][search][regex]=false
columns[2][data]=active
columns[2][name]=
columns[2][searchable]=true
columns[2][orderable]=true
columns[2][search][value]=
columns[2][search][regex]=false
columns[3][data]=notifications
columns[3][name]=
columns[3][searchable]=true
columns[3][orderable]=true
columns[3][search][value]=
columns[3][search][regex]=false
order[0][column]=0
order[0][dir]=asc
start=0
length=10
search[value]=
search[regex]=false
_=1452865138855
How can I set the jagged, associative array parameters to the Struts 2 Action?
I am looking for a way to handle this in the application layer (as opposed to rewriting the parameters in the server before passing them to the application).