Return Type?

Is there a command or procedure for getting a more precise type for my selection?

For example, how do I know if I have a Shape Node selected versus a Vertex? (both are type "mesh")

Thanks

Wow! Thats odd! :]
I never recognized this.

But you can differ between components and shapes pretty well.
For instance you can use filterExpand and ls:

CODE
string $selection[] = {"pCubeShape1"};
// Result: pCubeShape1 // stuff a shape in the $selection array
ls -s $selection;
// Result: pCubeShape1 // ls -s filters this shape correctly
size(ls -s $selection);
// Result: 1 // there is 1 shape item in the array

string $selection[] = {"pCube1.vtx[4]","pCube1.vtx[5]"};
// Result: pCube1.vtx[4] pCube1.vtx[5] // now we put vertices into the array
filterExpand -sm 31 $selection;
// Result: pCube1.vtx[4] pCube1.vtx[5] // selectionMask 31 is for vertices!
size(filterExpand -sm 31 $selection);
// Result: 2 // it correctly filters 2 vertices
size(ls -s $selection);
// Result: 0 // no shapes in this case of course

hope that may help :]
scream if you want more.