Fano line shapes generated by an excitonic layer in attenuated-total-reflection geometry and application to