Change detailview according to masterview in UISplitViewController

I have a UISplitViewController which has a searchfiled in the first row of its master view which is a tableview as we all know. And my detail view contains a collectionview i have to update my collectionviewcells according to the seacrhfield text. So how i update collectionview cells according to my result.

Check this tutorial out. Its kind of old, but the main idea is there:

It uses an extension and a class called FlickrSearchResults.