In Stargate Universe there is a spaceship called Destiny which travels the universe seeding planets with stargates and flying through stars to refuel by collecting the raw materials inside. The ship is also automated. I always thought that was a cool idea but I've been wondering if there was any previous science fiction work which this might be based on.
Note that I am not talking about using solar energy but actually flying into the star and collecting the materials inside.