Setting app:layout_behavior programmatically

I have a coordinator layout with a recyclerview which I would like to add programmatically. The reason why it's added programatically is because different fragments which inflate the coordinator la...