A statistical thermodynamic model for water near solid interfaces