Analytic stellar models in general relativity