1

I am reading iOS app extension programming guide and here is written the following:

While an extension is running, it communicates directly only with the host app. There is no direct communication between a running extension and its containing app; typically, the containing app isn’t even running while its extension is running. In addition, the containing app and the host app don’t communicate at all.

So, extension can be run even it's app doesn't. So, this mean, that extension has it's own process or run it in host app process??

Andrew
  • 15,357
  • 6
  • 66
  • 101
someUser
  • 965
  • 12
  • 24
  • 1
    Common sense would indicate that the host app would load it like any other shared library, making it part of the host app. Beyond that you'll have to ask someone at Apple. – borrrden Aug 11 '14 at 09:37
  • Yes, I also think that extension could be run in host app's process. But here is coming IPC between host and extension's apps. And though Apple says they cared read/write access, I am still anxious about that. – someUser Aug 11 '14 at 09:52
  • I think you might be misunderstanding the point of an extension. It is likely not an executable process that is "run", but rather functionality that is "loaded". I don't think you should be too concerned with the word "communicate". The point is that the containing app will not be exposed in any way by its extension. The extension is purely separate from the containing app. – borrrden Aug 12 '14 at 01:11

1 Answers1

2

The host app, containing app, and app extension are all separate processes. The host app and app extension communicate via IPC that is controlled by iOS and exposed to the developer through the limited app extension APIs.

Icydog
  • 467
  • 2
  • 6
  • Can you please provide the source of the information? – someUser Aug 27 '14 at 10:15
  • 1
    The docs from Apple are not always very clear or explicit about this, but if you create an app extension and play with the API a bit this will become clear. It's simple to determine that these things run in separate processes: simply run the containing app, the host app, and app extension, then look at the process list. – Icydog Aug 27 '14 at 20:10