Partial update/add/delete of a document using java

Documents are device related and there are 2 nested structures. use-case is get the device related data. Also, how to convert this curl to java
POST cisco_nia-eventagg/jobupdate/JS23EmkBPgJ20mqE2WE1/_update
{
"script" : {
"source":"ctx._source.allImageReco.add(params.newElement)",
"params": {
"newElement": {
"yes" : 121,
"yes1" : 1469050965
}
}}
}