Investigation into Structural Variation from 3D to 1D and Strong Second Harmonic Generation of the AHgPS4 (A+ = Na+, K+, Rb+, Cs+) Family.