isRow implementation

Implemented isRow, minor speed increase, and also did some documentation
and cleanup of both isRow and isTable