Class ModelReplicator

java.lang.Object
ca.mcscert.jpipe.operators.ModelReplicator

public final class ModelReplicator extends Object
Produces a List of Commands that copy all elements and support edges from a source model into a target model, without mutating the source.

The prefix parameter controls id qualification, following the same convention as JustificationModel.inline(Template, String):

  • blank / null → keep original ids unchanged
  • non-blank → prepend prefix: to plain ids; already-qualified ids (containing :) are kept as-is

When used inside a MergeFunction, the caller is responsible for registering aliases in the AliasRegistry — this utility does not touch the registry.

  • Method Details

    • replicate

      public static List<Command> replicate(String targetModelName, JustificationModel<?> source, String prefix)
      Returns commands that replicate source into targetModelName with element ids qualified by prefix.