EXCHANGE AGREEMENT by and between HERITAGE OAKS BANCORP and CASTLE CREEK CAPITAL PARTNERS IV, LP Dated as of October 29, 2014