/// <summary>
        /// Factory method initializing instance of <see cref="ProjectNames"/> with values retrieved from a DTE project.
        /// </summary>
        /// <param name="dteProject">DTE project to get project names for.</param>
        /// <returns>New instance of <see cref="ProjectNames"/>.</returns>
        public static async Task <ProjectNames> FromDTEProjectAsync(EnvDTE.Project dteProject, SVsSolution vsSolution)
        {
            Assumes.Present(dteProject);
            await NuGetUIThreadHelper.JoinableTaskFactory.SwitchToMainThreadAsync();

            string fullname         = dteProject.FullName;
            string uniqueName       = dteProject.GetUniqueName();
            string shortName        = dteProject.GetName();
            string customUniqueName = await dteProject.GetCustomUniqueNameAsync();

            string projectId = GetProjectGuid(dteProject, vsSolution);

            return(new ProjectNames(
                       fullName: fullname,
                       uniqueName: uniqueName,
                       shortName: shortName,
                       customUniqueName: customUniqueName,
                       projectId: projectId));
        }