I open a Dialog using Primefaces dialog framework
RequestContext.getCurrentInstance().openDialog("myDialog", options, null);
Then, I want to update a component in the base page after the dialog's close event. I know we could add a 'dialogReturn' ajax event
<p:ajax event="dialogReturn" update = ":form:colors" />
But how to do this programmatically using the dialog framework?