/**
  * Factory method for path query. Getting all changes from source to target.
  *
  * @param source source version
  * @param target target version
  * @param allVersions include all versions, from all branches
  * @param includeCp include changepackages
  * @return query
  */
 public static PathQuery pathQuery(
     PrimaryVersionSpec source,
     PrimaryVersionSpec target,
     boolean allVersions,
     boolean includeCp) {
   final PathQuery query = VersioningFactory.eINSTANCE.createPathQuery();
   query.setSource(ModelUtil.clone(source));
   query.setTarget(ModelUtil.clone(target));
   query.setIncludeAllVersions(allVersions);
   query.setIncludeChangePackages(includeCp);
   return query;
 }