Coming from the Java world, I cannot still understand exactly what Swift submodules are and are not in terms of Java packages' counterparts.
- How Swift modules and submodules relate to jars and packages in the Java world?
- Can you actually import from submodules, e.g. by writing import Module.Submodule1(...).SubmoduleN.MyClass?
- Are submodules bound to directory trees, just like Java packages? If they are not, then how, where are submodules defined?
(I have not been able to find answers to these questions neither on Apple's online specification of Swift nor in the free book distributed by them. I've asked on some dev lists but the info I got there is in contradiction with Apple's documentation for the Package Manager, especially regarding the third point.)