Welcome to Headwind MDM Q&A, where you can ask questions and receive answers from other members of the community.

Please do not post bug reports, missing feature requests, or demo inquiries. If you have such an inquiry, submit a contact form.

0 votes

Dear members of the forum,

I was wondering what's actually the difference between the case when MDMService.connect() returns true and a later callback on ResultHandler.onMDMConnected(). Similar question I have with HeadwindMDM.connect() and EventHandler.onHeadwindMDMConnected()

I assume the first return of true from connect() just means that API-level (software) connection is successful, whereas the later call of the callback would mean that a network connection has been successfully established which yielded a current copy of config/preferences/etc. If so, then, EventHandler.onHeadwindMDMConnected() is probably equivalent to as ResultHandler.onMDMConnected()? - just depending on what part of the API one is using?

In general, I'm a little confused about the phrase "running outside Headwind MDM" in the documentation. Do I understand it right that this means that the HMDM launcher is not installed (or running?) on the respective device?

Very man thanks in advance and kind regards, Daniel Schaffrath

https://h-mdm.com/headwind-mdm-api/

ago by (270 points)

1 Answer

+1 vote

The connection is asynchronous.

When MDMService.connect() returns true, this means the connection process is initiated without issues (for example, as you mentioned, Headwind MDM launcher should be installed on the device, otherwise you get an immediate error ERROR_NO_MDM).

When the service connection is completed, a callback ResultHandler.onMDMConnected() is called.

ago by (45.8k points)
...