[POC] Class based indexes

Oh, I get it. either fields or field-names. The code needs to be more explicit (and defensive) about it.