Ejemplo n.º 1
0
        public CodePreviewDialog(IActiveRecordDescriptor descriptor) : this()
        {
            codeproviderFactory =
                ServiceRegistry.Instance[typeof(ICodeProviderFactory)] as ICodeProviderFactory;
            ICodeDomGenerator codeDomGen =
                ServiceRegistry.Instance[typeof(ICodeDomGenerator)] as ICodeDomGenerator;

            typeDecl = codeDomGen.Generate(descriptor);

            language.ValueMember = "Label";

            foreach (CodeProviderInfo info in codeproviderFactory.GetAvailableProviders())
            {
                language.Items.Add(info);
            }

            language.SelectedIndex = 0;
        }
Ejemplo n.º 2
0
		public ProjectGenerator(ICodeDomGenerator domGenerator, ICodeProviderFactory providerFactory)
		{
			_domGenerator = domGenerator;
			_providerFactory = providerFactory;
		}
Ejemplo n.º 3
0
 public ProjectGenerator(ICodeDomGenerator domGenerator, ICodeProviderFactory providerFactory)
 {
     _domGenerator    = domGenerator;
     _providerFactory = providerFactory;
 }