[NuGet] Rework project templates with NuGet packages.

Determine projects and associated NuGet package references in
project template classes.
Make ProjectTemplatePackageInstaller abstract.