简体   繁体   English

Mono/Linux 上是否有与 IFilter 等效的功能?

[英]Is there an equivalent to IFilter on Mono/Linux?

I'm converting an app from .NET/Windows to mono/linux, but I can't find any information about IFilters.我正在将应用程序从 .NET/Windows 转换为 mono/linux,但我找不到任何有关 IFilters 的信息。 I'm aware of the Microsoft IFilters for Office, Adobe and FoxIt IFilters for PDF, but don't know if they work on Linux and/or Mono, or if there is something functionally equivalent (used for extracting plain text from proprietary forms).我知道 Microsoft IFilters for Office、Adobe 和 FoxIt IFilters for PDF,但不知道它们是否适用于 Linux 和/或 Z5D9B47BD3B65072E0D5D5DAF55F01 功能等价的形式.

IFilter is a native Windows API, not a .NET API. IFilter 是原生 Windows API,而不是 .NET API。

On Linux you could use the filters from a search indexer such as Beagle.在 Linux 上,您可以使用搜索索引器(例如 Beagle)中的过滤器。

As far as I can tell IFiler technology is still used in recent applications.据我所知,最近的应用程序仍在使用 IFiler 技术。 In its original design (around 1996 or before) these are COM objects written in C or C++.在其原始设计(大约 1996 年或更早)中,这些是用 C 或 C++ 编写的 COM 对象。 Most IFilters available from past years will not work on 64bit.过去几年可用的大多数 IFilter 都不适用于 64 位。 If you are building an app outside Windows, you may need to create the code that loads and calls the IFilters.如果您在 Windows 之外构建应用程序,您可能需要创建加载和调用 IFilter 的代码。

Any implementation that wants to use an IFilter needs to have some interface to load and call the IFilter in memory, point it to a file and kick it to read contents, then kick it a few times more to pull the text result from a memory buffer.任何想要使用 IFilter 的实现都需要有一些接口来加载和调用 memory 中的 IFilter,将其指向一个文件并踢它以读取内容,然后再踢几次以从 memory 缓冲区中提取文本结果. Modern implementations using IFilters use more advanced memory protection to flush the memory when leaks happen, not uncommon in C coding... A few samples (from around 2003 or 2005) are available on the internet, they should work, as long as you respect the old style interface. Modern implementations using IFilters use more advanced memory protection to flush the memory when leaks happen, not uncommon in C coding... A few samples (from around 2003 or 2005) are available on the internet, they should work, as long as you respect旧式界面。

Hope this is of help.希望这是有帮助的。

Not sure if this is what you're using, but according to MSDN IFilter (as related to the Indexing Service) is obsolete.不确定这是否是您正在使用的,但根据 MSDN IFilter (与索引服务相关)已过时。 As such I'd be surprised if it was reimplemented in Mono.因此,如果它在 Mono 中重新实现,我会感到惊讶。

That said, many .NET assemblies can be dropped into a Mono application without recompilation.也就是说,许多.NET 程序集无需重新编译即可放入 Mono 应用程序中。 Though it seems more likely that this would be the case with a third party DLL than one from Microsoft, it may be worth a shot to see if that will work in your case.尽管第三方 DLL 似乎更有可能出现这种情况,而不是 Microsoft 的情况,但可能值得一试,看看这是否适用于您的情况。

http://msdn.microsoft.com/en-us/library/ms691105(v=vs.85).aspx http://msdn.microsoft.com/en-us/library/ms691105(v=vs.85).aspx

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM