I'm trying to implement my own paging for IEnumerable collections. So, I have a class called PagedList. I'm done with the class itself, I just need to write an HtmlHelper extension method that will render the actual pages. This would be the simplest way to go (at least I can think of):
public static MvcHtmlString Paginate<TModel>(this HtmlHelper<TModel>,string url){
//do the stuff here
return new MvcHtmlString("Hi");
}
But, is it possible to make this method available ONLY in those views that are strongly typed to PagedList?