public override void Generate()
		{
			foreach (Table table in (from x in _model.Database.Tables where x.Generated orderby x.Name select x))
			{
				if (table.Generated)
				{
					foreach (TableComponent component in table.ComponentList)
					{
						DomainComponentCollectionExtenderTemplate template = new DomainComponentCollectionExtenderTemplate(_model, component);
						string fullFileName = RELATIVE_OUTPUT_LOCATION + template.FileName;
						ProjectItemGeneratedEventArgs eventArgs = new ProjectItemGeneratedEventArgs(fullFileName, template.FileContent, ProjectName, this, false);
						OnProjectItemGenerated(this, eventArgs);
					}
				}
			}
			ProjectItemGenerationCompleteEventArgs gcEventArgs = new ProjectItemGenerationCompleteEventArgs(this);
			OnGenerationComplete(this, gcEventArgs);
		}
Esempio n. 2
0
        public override void Generate()
        {
            foreach (Table table in (from x in _model.Database.Tables where x.Generated orderby x.Name select x))
            {
                if (table.Generated)
                {
                    foreach (TableComponent component in table.ComponentList)
                    {
                        DomainComponentCollectionExtenderTemplate template = new DomainComponentCollectionExtenderTemplate(_model, component);
                        string fullFileName = RELATIVE_OUTPUT_LOCATION + template.FileName;
                        ProjectItemGeneratedEventArgs eventArgs = new ProjectItemGeneratedEventArgs(fullFileName, template.FileContent, ProjectName, this, false);
                        OnProjectItemGenerated(this, eventArgs);
                    }
                }
            }
            ProjectItemGenerationCompleteEventArgs gcEventArgs = new ProjectItemGenerationCompleteEventArgs(this);

            OnGenerationComplete(this, gcEventArgs);
        }