private async Task <IList <GeneratedTemplate> > GetGeneratedTemplates() { var template = await GetTemplate(exportProducts : true, fixedServiceNameParameter : true, createApplicationInsightsInstance : true, exportSwaggerDefinition : true, replaceSetBackendServiceBaseUrlAsProperty : true); var templatesGenerator = new TemplatesGenerator(); var generatedTemplates = templatesGenerator.Generate(template.ToString(), true, true, true, true, false, separateSwaggerFile: true); return(generatedTemplates); }
private void buttonGenerateTemplates_Click(object sender, EventArgs e) { this.Visible = false; var templateForm = new TemplatesGenerator(); templateForm.ShowDialog(); this.Visible = true; devices = client.DiscoverDevicesInRange(); if (devices.Count() > 0) { comboBoxSelectDevice.DataSource = devices; comboBoxSelectDevice.DisplayMember = "DeviceName"; comboBoxSelectDevice.ValueMember = "DeviceAddress"; comboBoxSelectDevice.Focus(); comboBoxSelectDevice.SelectedIndex = 0; } templates = FileCoder.EncodeFileToLEDCubeTemplateModel(); if (templates != null) { comboBoxTemplatesSelect.Items.AddRange(templates.Select(x => x.Name).ToArray()); } }
public void Initialize() { _templatesGenerator = new TemplatesGenerator(); _sourceTemplate = Utils.GetEmbededFileContent("APIManagementTemplate.Test.SamplesTemplate.template.json"); _generatedTemplates = _templatesGenerator.Generate(_sourceTemplate, false, false, listApiInProduct: true); }
public void Initialize() { _templatesGenerator = new TemplatesGenerator(); _sourceTemplate = Utils.GetEmbededFileContent("APIManagementTemplate.Test.SamplesTemplate.templateSwagger.json"); _generatedTemplates = _templatesGenerator.Generate(_sourceTemplate, true, true, separateSwaggerFile: true); }