当前位置: 首页>>代码示例>>C#>>正文


C# AssemblyList.OpenAssembly方法代码示例

本文整理汇总了C#中ICSharpCode.ILSpy.AssemblyList.OpenAssembly方法的典型用法代码示例。如果您正苦于以下问题:C# AssemblyList.OpenAssembly方法的具体用法?C# AssemblyList.OpenAssembly怎么用?C# AssemblyList.OpenAssembly使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ICSharpCode.ILSpy.AssemblyList的用法示例。


在下文中一共展示了AssemblyList.OpenAssembly方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: AddToList

 private void AddToList(AssemblyList list, string FullName)
 {
     AssemblyNameInfo reference = new AssemblyNameInfo(FullName);
     string file = GacInterop.FindAssemblyInNetGac(reference);
     if (file != null)
         list.OpenAssembly(file);
 }
开发者ID:BahNahNah,项目名称:dnSpy,代码行数:7,代码来源:OpenListDialog.xaml.cs

示例2: MainWindow_Loaded

        void MainWindow_Loaded(object sender, RoutedEventArgs e)
        {
            ILSpySettings spySettings = this.spySettings;
            this.spySettings = null;

            // Load AssemblyList only in Loaded event so that WPF is initialized before we start the CPU-heavy stuff.
            // This makes the UI come up a bit faster.
            this.assemblyList = assemblyListManager.LoadList(spySettings, sessionSettings.ActiveAssemblyList);

            ShowAssemblyList(this.assemblyList);

            string[] args = Environment.GetCommandLineArgs();
            for (int i = 1; i < args.Length; i++) {
                assemblyList.OpenAssembly(args[i]);
            }
            if (assemblyList.GetAssemblies().Length == 0)
                LoadInitialAssemblies();

            SharpTreeNode node = FindNodeByPath(sessionSettings.ActiveTreeViewPath, true);
            if (node != null) {
                SelectNode(node);

                // only if not showing the about page, perform the update check:
                ShowMessageIfUpdatesAvailableAsync(spySettings);
            } else {
                AboutPage.Display(decompilerTextView);
            }
        }
开发者ID:FriedWishes,项目名称:ILSpy,代码行数:28,代码来源:MainWindow.xaml.cs

示例3: Main


//.........这里部分代码省略.........
					
			}


			if (appPath == null) {
			
				Console.WriteLine ("directory/to/all/your/dll missing");
				showUsage ();
				return;
			}

			if (slnName == null && outLanguageType==LAN_TYPE_CSHARP) {

				Console.WriteLine ("Solution Name missing");
				showUsage ();
				return;
			}


			Console.WriteLine ("Decompiling all dll in  " + appPath);
			Console.WriteLine ("Please wait...");

			DirectoryInfo di = new DirectoryInfo(appPath);
			appPath = di.FullName;
			FileInfo[] dllFileInfoList = di.GetFiles("*.dll");
			FileInfo[] exeFileInfoList = di.GetFiles ("*.exe");


			AssemblyList asmlist = new AssemblyList ("mylistname");

			foreach (var dllfile in dllFileInfoList)
			{
				bool bDecompile = isDecompilingFile (dllfile.FullName, onlyDecompilingFileNameList);
				asmlist.OpenAssembly (dllfile.FullName,!bDecompile);
			}

			foreach (var dllfile in exeFileInfoList)
			{
				bool bDecompile = isDecompilingFile (dllfile.FullName, onlyDecompilingFileNameList);

				asmlist.OpenAssembly (dllfile.FullName,!bDecompile);
			}


			if (libPath != null) {
				di = new DirectoryInfo(libPath);
				libPath = di.FullName;
				dllFileInfoList = di.GetFiles("*.dll");
				foreach (var dllfile in dllFileInfoList) {
					asmlist.OpenAssembly (dllfile.FullName,true);
				}
			}
			


			StringBuilder projSln = new StringBuilder ();
			projSln.Append ("Microsoft Visual Studio Solution File, Format Version 11.00\n# Visual Studio 2010\n");

			StringBuilder globSec = new StringBuilder ();
			Guid slnProjGuid =  Guid.NewGuid();

			int num = 0;
			LoadedAssembly [] ls = asmlist.GetAssemblies ();
			var decompilationOptions = new DecompilationOptions ();
			decompilationOptions.FullDecompilation = true;
			decompilationOptions.assenmlyList = asmlist;
开发者ID:aerror2,项目名称:ILSpy-For-MacOSX,代码行数:67,代码来源:Main.cs

示例4: AddToList

		private void AddToList(AssemblyList list, string FullName)
		{
			AssemblyNameReference reference = AssemblyNameReference.Parse(FullName);
			string file = GacInterop.FindAssemblyInNetGacOrWinMetadata(reference);
			if (file != null)
				list.OpenAssembly(file);
		}
开发者ID:x-strong,项目名称:ILSpy,代码行数:7,代码来源:OpenListDialog.xaml.cs


注:本文中的ICSharpCode.ILSpy.AssemblyList.OpenAssembly方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。