// Update the comment.
company.setComment(company.getComment() + " Updated.");
// Update the companies on the server.
Company[] companies = companyService.updateCompanies(new Company[] {company});
for (Company updatedCompany : companies) {
System.out.printf(
"Company with ID \"%d\", name \"%s\", and comment \"%s\" was updated.\n",
updatedCompany.getId(), updatedCompany.getName(), updatedCompany.getComment());