/// <summary> /// Construct a Template object for the main template in a package. /// </summary> /// <param name="location">The template location as a package location.</param> /// <include file="../Shared/Help.xml" path="Help/string/param[@name='switches']"></include> /// <include file="../Shared/Help.xml" path="Help/string/param[@name='key']"></include> public Template(PackageTemplateLocation location, string switches = "", string key = "") { if (location == null) { throw new ArgumentNullException("location"); } HotDocs.Sdk.TemplateInfo ti = location.GetPackageManifest().MainTemplate; FileName = ti.FileName; Location = location; Switches = string.IsNullOrEmpty(switches) ? "" : switches; Key = string.IsNullOrEmpty(key) ? "" : key; }
/// <summary> /// Construct a Template object for the main template in a package. /// </summary> /// <param name="location">The template location as a package location.</param> /// <include file="../Shared/Help.xml" path="Help/string/param[@name='switches']"></include> /// <include file="../Shared/Help.xml" path="Help/string/param[@name='key']"></include> public Template(PackageTemplateLocation location, string switches = "", string key = "") { if (location == null) throw new ArgumentNullException("location"); HotDocs.Sdk.TemplateInfo ti = location.GetPackageManifest().MainTemplate; FileName = ti.FileName; Location = location; Switches = string.IsNullOrEmpty(switches) ? "" : switches; Key = string.IsNullOrEmpty(key) ? "" : key; }