Process.Net
ProcessSharp的构造函数,对应的测试是
https://github.com/lolp1/Process.NET/blob/master/test/Process.NET.Test/Core/ProcessSharpTest.cs
/// <summary>/// Initializes a new instance of the <see cref="ProcessSharp" /> class./// </summary>/// <param name="native">The native process.</param>/// <param name="type">The type of memory being manipulated.</param>public ProcessSharp(System.Diagnostics.Process native,MemoryType type){native.EnableRaisingEvents = true;native.Exited += (s, e) =>{ProcessExited?.Invoke(s, e);HandleProcessExiting();};Native = native;Handle = MemoryHelper.OpenProcess(ProcessAccessFlags.AllAccess, Native.Id);switch (type){case MemoryType.Local:Memory = new LocalProcessMemory(Handle);break;case MemoryType.Remote:Memory = new ExternalProcessMemory(Handle);break;default:throw new ArgumentOutOfRangeException(nameof(type), type, null);}native.ErrorDataReceived += OutputDataReceived;native.OutputDataReceived += OutputDataReceived;ThreadFactory = new ThreadFactory(this);ModuleFactory = new ModuleFactory(this);MemoryFactory = new MemoryFactory(this);WindowFactory = new WindowFactory(this);}
https://github.com/lolp1/Process.NET/blob/master/src/Process.NET/Memory/ExternalProcessMemory.cs
可以尝试转换HearthBuddy中的Class276中的方法
internal IntPtr method_33(IntPtr intptr_37, string string_0, params Class276.Enum20[] enum20_0){while (intptr_37 != IntPtr.Zero){using (AllocatedMemory allocatedMemory = this.externalProcessMemory_0.CreateAllocatedMemory(256)){allocatedMemory.AllocateOfChunk<IntPtr>("Itr");IntPtr intPtr;while ((intPtr = this.method_35(intptr_37, allocatedMemory["Itr"])) != IntPtr.Zero){IntPtr intPtr2 = this.method_37(intPtr);if (this.externalProcessMemory_0.ReadStringA(intPtr2) == string_0){if (enum20_0 != null){Class276.Enum20[] array = this.method_31(intPtr);if (array.Length != enum20_0.Length || !array.SequenceEqual(enum20_0)){continue;}}return intPtr;}}intptr_37 = this.method_25(intptr_37);}}return IntPtr.Zero;}
转载于:https://www.cnblogs.com/chucklu/p/11376479.html
Process.Net相关推荐
- 使用Java监控工具出现 Can't attach to the process
问题重现 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 ➜ jinfo -flags 3032 Attaching ...
- Mr. Process的一生-Linux内核的社会视角 (2)启动
原文地址: http://www.manio.org/cn/startup-of-linux-view-of-society.html 其实这才应该是这一系列文章的第一节,因为这篇文章讲的是盘古开天地 ...
- 【linux】在CentOS7上更改端口号时报错:Job for sshd.service failed because the control process exited with error
1.问题描述 在在CentOS7上更改端口号时报错: Job for sshd.service failed because the control process exited with error ...
- 【Qt】ubuntu14.04.5 qt5.6中使用opencv3.4报错:Using GTK+ 2.x and GTK+ 3 in the same process is not supported
问题描述 ubuntu14.04.5 qt5.6中使用opencv3.4报错: Using GTK+ 2.x and GTK+ 3 in the same process is not support ...
- 守护进程中创建的对象php,在PHP中生成守护进程(Daemon Process)
前两天看到一篇文章<如何使用PHP编写daemon process>,其中对核心代码却没有细说,我又查了一些资料,还看了一本<理解Unix进程>,才搞明白生成守护进程的时候发生 ...
- template.process(root, out)的用法(shiro项目中来的九)
假如你现在还在为自己的技术担忧,假如你现在想提升自己的工资,假如你想在职场上获得更多的话语权,假如你想顺利的度过35岁这个魔咒,假如你想体验BAT的工作环境,那么现在请我们一起开启提升技术之旅吧,详情 ...
- Error:Execution failed for task ':app:dexDebug'. com.android.ide.common.process.ProcessException
异常Log: Error:Execution failed for task ':app:dexDebug'. > com.android.ide.common.process.Process ...
- symfony2 Process 组件的学习笔记
2019独角兽企业重金招聘Python工程师标准>>> 安装 composer require "symfony/process:2.7.1" ##描述 proc ...
- 用计算机的英语造句process,process的用法总结大全
process的意思 n. 过程,工序,做事方法,工艺流程 vt. 加工,处理,审阅,审核 vi. 列队行进 adj. 经过特殊加工(或处理)的 变形:过去式: processed: 现在分词:pro ...
- 关于v$process与v$session中process的理解
v$session有个process字段,V$PROCESS有个SPID字段,这两个字段是不是一个意思呢?是不是都代表会话的操作系统进程呢? 官方文档上的解释: SPID VARCHAR2( ...
最新文章
- 用什么擦地最干净脑筋急转弯_22个数学脑筋急转弯答案,你能全部做出来吗?...
- 电子商务中遇到组合搜索的问题
- 皮一皮:中国好邻居!
- (winform cookie)如何向某网址Post信息,并得到CookieContainer以便以后直接通过验证...
- Chapter 1 Securing Your Server and Network(1):选择SQL Server运行账号
- 大牛书单 | 大数据存储方向好书分享
- iOS沙盒路径的查看和使用
- 递推-练习2--noi3525:上台阶
- c语言编写电子秒表程序,电子秒表C程序.doc
- 下面哪个选项不是oracle用户,作业三(有答案)
- 打开outlook2010里面的链接显示 “由于本机的限制,该操作已被取消。请与系统管理员联系。”解决方法...
- python填充nan_Pandas的数据清洗-填充NaN数据
- 【Android工具】更新Yandex网页剪辑插件测试!可以安装PCchrome插件的手机浏览器!...
- 数据可视化技术:python数据可视化工具库汇总(共21个)
- python-docx官方文档翻译--用户指南06--使用页眉和页脚
- Postgresql进程卡住无法退出原因和解决方法
- HTML下拉菜单怎么做成横向,JQuery实现绚丽的横向下拉菜单
- element表单校验输入框手动清空时出现XXX is required提示
- 罗尔定理的推论+一元微积分
- kafka关于副本的理解
热门文章
- CVPR2017: Densecap复现记录
- kubernetes 中 calico 组件的 calicoctl 工具的使用示例及 BGP 相关配置
- 如何做到图片无损压缩?speedpdf在线转换操作步骤
- jq在线引用地址大全
- r中 新建HTML默认文档的快捷键,在文件夹里新建文本档的快捷键是什么?
- flinto导出html,Sketch绝佳搭配!30秒制作交互原型的次时代神器Flinto
- C#打印条码的几种方式
- 关于AndroidStudio中Gradle文件引发的问题导致HelloWorld无法运行的解决方法
- (二)win10环境下使用Hyper-V进行虚拟机创建
- JSON JOLT介绍 及语法详解-shift篇