// create entry to update
final TestOlingo2ResponseHandler<ODataEntry> entryHandler = new TestOlingo2ResponseHandler<ODataEntry>();
olingoApp.create(edm, MANUFACTURERS, getEntityData(), entryHandler);
ODataEntry createdEntry = entryHandler.await();
LOG.info("Created Entry: {}", prettyPrint(createdEntry));
Map<String, Object> data = getEntityData();
@SuppressWarnings("unchecked")
Map<String, Object> address = (Map<String, Object>) data.get(ADDRESS);
data.put("Name", "MyCarManufacturer Renamed");
address.put("Street", "Main Street");
final TestOlingo2ResponseHandler<HttpStatusCodes> statusHandler =
new TestOlingo2ResponseHandler<HttpStatusCodes>();
olingoApp.update(edm, TEST_CREATE_MANUFACTURER, data, statusHandler);
statusHandler.await();
statusHandler.reset();
data.put("Name", "MyCarManufacturer Patched");
olingoApp.patch(edm, TEST_CREATE_MANUFACTURER, data, statusHandler);
statusHandler.await();
entryHandler.reset();
olingoApp.read(edm, TEST_CREATE_MANUFACTURER, null, entryHandler);
ODataEntry updatedEntry = entryHandler.await();
LOG.info("Updated Entry successfully: {}", prettyPrint(updatedEntry));
statusHandler.reset();
olingoApp.delete(TEST_CREATE_MANUFACTURER, statusHandler);