Reference with source nodes under deleted roots shall be made direct for later resolve from e.g. ReferenceMacro. Query in RefMacro like 'inputNode.ref1' when inputNode lives in deleted parent fails to resolve as it can't access inputNode's model to resolve target by nodeid.
Besides, references with *targets* under deleted roots are updated.
Defect: root nodes from root map rules that doesn't consume input root are not added to outcome if inplace transformations are on.
Fix: we tell changed roots from newly added now. Newly added are injected into input model if inplace transformation is on (this effectively enables inplace tranformations for templates with create root rules and root map rules for non-root input nodes).
dependencies builder wants to known about roots added during template transformation, too. Send it update signal regardless of whether the output model is the new one or the one from previous input. This updates structures in IncrementalDependenciesBuilder that helps it find original roots for newly added. The issue surfaced once inplace transformation have been enabled for create/map root rules.
Enable inplace transformations when there are root mapping rules and some roots have been consumed by these rules. Record such roots as deleted with delta builder, the same way we do for drop rules.
Minor refactoring
Merge remote-tracking branch 'origin/master' into 3.1/artem/default
Merge branch 'master' into 3.1/artem/default
ReferenceMacro to produce internal (implementation-specific) FQN of a generated class seems to be too much of a hack - it's the only place I've found that takes this approach. Replaced with InternalClassifierType.
Do not try to make reference direct if it's already direct.
Imagine model with root A, child B, and child B.C referencing B with direct reference (immatureTargetNode != null, ==B). Delete root A from model. While B and C is deleted, reference to B is made direct. So far so good. makeDirect (which effectively goes through getTargetSModelReference() and makeIndirect()) checks B is not disposed and is its model is available (1), and does SReferenceBase#makeMature.
 makeMature records nodeid (for StaticReference) and throws away immatureTargetNode. Later, in getTargetNode, this reference can't be resolved (2) and makeDirect ends up as null.
 Both (1) and (2) happens due to the nature of SNode.unRegisterFromModel - first the node is thrown away from the nodeid-node map, then children are processed, then model is set to null. Hence at makeIndirect call B, which is in process of being deleted, is not recognized as disposed and its model is still not null (would happen once all children of B are processed). However, B's nodeid is already gone from model's nodeid-node map, and resolve (2) fails.

Perhaps, alternative fixes (in unRegisterFromModel) are possible:  like model = null prior to children disposal or unregister from nodeid-node map *after* children are processed. However, proposed fix seems most straightforward (let alone fast and safe) solution.
Merge remote-tracking branch 'origin/master' into 3.1/artem/default