protected internal virtual void TransformTemplateToFile(ITextTemplatingSession session, ProjectItem groupDirectoryProjectItem, string templatePath, string templateContent, string typeName) { string directoryPath = _solutionManager.GetProjectItemFullPath(groupDirectoryProjectItem); _textTemplatingSessionHost.Session = session; string transformedTemplate = _textTemplating.ProcessTemplate(templatePath, templateContent); string newFilePath = WriteToFile(directoryPath, typeName, transformedTemplate); _solutionManager.AddFileToDirectoryProjectItem(groupDirectoryProjectItem, newFilePath); }