Characterization of scalar-type spectral operators