AFAIK, knowledge checks tell you about a species (e.g., Humans), not a specific creature (Joe Schmoe, Bartender).
Well, I'd say that depends.
If we're talking about Humanoids, then a Knowledge (local) check should give some hint as to what any given creature's class levels are (because you should also know something about traditional garb for creatures of certain professions).
If we're talking about creatures in general, then a Knowledge (local) or Gather Information check can reasonably also let you know if you're fighting a creature that's distinctive enough to have gained a class level (these creatures are usually somewhat in/famous), as well as some clue as to what that class level might be. Granted, the way I'd work Gather Information in this case would be a bit different than Knowledge (local).
Problem is, I tag on classlevels on every other monster I use. For instance in the last few sessions I had a Gargoyle with fewer racial HD and a few levels in sorcerer, gargoyles with fighter levels and the dungeon crasher variant and a vampire with rogue levels.
I'll give an other example of something I might dream up. I'm just thinking out loud now.
Corpsecrafted Firbolg skeleton with fighterlevels and willing deformity Tall or Inhuman Reach. So, what knowledgecheck gives what?
I'm leaning toward 3 checks, but that will be much to identify 1 creature
Religion. DC 15 gives skeleton traits, DC 20 gives corpsecrafted. DC 25b will give the extra reach
Nature to recognise the Firbolg (assuming it is a giant. AFB)
Local to recognize the classlevels
What if I give it Martial study Thicket of blades or something. Martial Lore? This is getting ridiculous.
So, any suggestions on how to handle it? Just make it 1 check and keep pumping the DC? Are classlevels even visible? Martial stances?