Some questions about SDK

Discussion related to "Everything" 1.5 Alpha.
Post Reply
err_24546
Posts: 39
Joined: Wed Oct 11, 2023 1:47 am

Some questions about SDK

Post by err_24546 »

Hi.
Using the SDK over IPC with EV 1.5.
  • 1. How can a query in progress be stopped? Note that I don't want to use EVERYTHING_IPC_EXIT to exit Everything, just stop an ongoing search. Maybe running an empty search?
    2. Does EVERYTHING_IPC_IS_DB_BUSY only react if a search is in progress, or is there a better way to know if a query is in progress?
Thanks.
void
Developer
Posts: 16428
Joined: Fri Oct 16, 2009 11:31 pm

Re: Some questions about SDK

Post by void »

1. How can a query in progress be stopped?
Performing another query will cancel the old query.
Ending your process will also cancel the current query.

To cancel a query, I recommend doing an empty search.
This query will be instant and use no memory.


2. Does EVERYTHING_IPC_IS_DB_BUSY only react if a search is in progress, or is there a better way to know if a query is in progress?
You will need to poll EVERYTHING_IPC_IS_DB_BUSY every few milliseconds to determine if the Everything database is busy.
This will return TRUE for other queries too, so I recommend assuming Everything is still querying until you receive your query reply.

Use bWait=FALSE with Everything_Query.
Assume Everything is querying until Everything_IsQueryReply succeeds.
Post Reply