Пример #1
0
 public LiquidTemplate(string language, string template, string data, object model, string toolchainVersion, CodeGeneratorSettingsBase settings)
 {
     _language         = language;
     _template         = template;
     _data             = data;
     _model            = model;
     _toolchainVersion = toolchainVersion;
     _settings         = settings;
 }
 public LiquidTemplate(
     string language,
     string template,
     Func <string, string, string> templateContentLoader,
     object model,
     string toolchainVersion,
     CodeGeneratorSettingsBase settings)
 {
     _language = language;
     _template = template;
     _templateContentLoader = templateContentLoader;
     _model            = model;
     _toolchainVersion = toolchainVersion;
     _settings         = settings;
 }
Пример #3
0
 /// <summary>Initializes a new instance of the <see cref="ValueGeneratorBase" /> class.</summary>
 /// <param name="settings">The settings.</param>
 protected ValueGeneratorBase(CodeGeneratorSettingsBase settings)
 {
     _settings = settings;
 }
Пример #4
0
 /// <summary>Initializes a new instance of the <see cref="DefaultTemplateFactory"/> class.</summary>
 /// <param name="settings">The settings.</param>
 /// <param name="assemblies">The assemblies containing embedded Liquid templates.</param>
 public DefaultTemplateFactory(CodeGeneratorSettingsBase settings, Assembly[] assemblies)
 {
     _settings   = settings;
     _assemblies = assemblies;
 }
Пример #5
0
 /// <summary>Initializes a new instance of the <see cref="DefaultTemplateFactory"/> class.</summary>
 /// <param name="settings">The settings.</param>
 public DefaultTemplateFactory(CodeGeneratorSettingsBase settings)
 {
     _settings = settings;
 }
 /// <summary>Initializes a new instance of the <see cref="TypeResolverBase" /> class.</summary>
 /// <param name="settings">The settings.</param>
 protected TypeResolverBase(CodeGeneratorSettingsBase settings)
 {
     _settings = settings;
 }
Пример #7
0
 /// <summary>Initializes a new instance of the <see cref="GeneratorBase"/> class.</summary>
 /// <param name="rootObject">The root object.</param>
 /// <param name="typeResolver">The type resolver.</param>
 /// <param name="settings">The settings.</param>
 protected GeneratorBase(object rootObject, TypeResolverBase typeResolver, CodeGeneratorSettingsBase settings)
 {
     RootObject = rootObject;
     _resolver  = typeResolver;
     _settings  = settings;
 }
Пример #8
0
 public DefaultTemplateFactory(CodeGeneratorSettingsBase settings)
     : this(settings, new Assembly[0])
 {
     // TODO: Also remove Assembly.Load after ctor has been removed
 }