Density Functional Calculation Of X-Ray Absorption Spectra Within The Core Hole Approximation: An Implementation In Nwchem