<commit_before>package org.jboss.loom.migrators._ext.process;


import java.io.File;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Stack;
import org.apache.commons.lang.StringUtils;
import org.jboss.dmr.ModelNode;
import org.jboss.loom.actions.CliCommandAction;
import org.jboss.loom.actions.CopyFileAction;
import org.jboss.loom.actions.IMigrationAction;
import org.jboss.loom.actions.ManualAction;
import org.jboss.loom.actions.ModuleCreationAction;
import org.jboss.loom.actions.XsltAction;
import org.jboss.loom.conf.Configuration;
import org.jboss.loom.ex.MigrationException;
import org.jboss.loom.migrators._ext.ActionDefs;
import org.jboss.loom.migrators._ext.ActionDefs.CliActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.CopyActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.ManualActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.ModuleActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.XsltActionDef;
import org.jboss.loom.migrators._ext.ContainerOfStackableDefs;
import org.jboss.loom.migrators._ext.DefinitionBasedMigrator;
import org.jboss.loom.migrators._ext.MigratorDefinition;
import org.jboss.loom.spi.IConfigFragment;
import org.jboss.loom.utils.DirScanner;
import org.jboss.loom.utils.Utils;
import org.jboss.loom.utils.el.IExprLangEvaluator;
import org.jboss.loom.utils.el.IExprLangEvaluator.JuelCustomResolverEvaluator;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 *  Processor for migrator definitions from .mig.xml files.
 *  These define:
 * 
 *    * JAXB classes, coded as Groovy files.
 *    * Queries which result in a list of IConfigFragment (typically, backed by those JAXB classes).
 *    * ForEach iterators which iterate over results of queries.
 *      * ForEach's define a variable which is available in EL and sub-contexts.
 * 
 *    * Nested elements which result in actions.<commit_msg>imports<commit_after>package org.jboss.loom.migrators._ext.process;


import java.io.File;
import java.util.HashMap;
import java.util.LinkedList;
import java.util.List;
import java.util.Map;
import java.util.Stack;
import org.apache.commons.lang.StringUtils;
import org.jboss.loom.actions.CliCommandAction;
import org.jboss.loom.actions.CopyFileAction;
import org.jboss.loom.actions.IMigrationAction;
import org.jboss.loom.actions.ManualAction;
import org.jboss.loom.actions.ModuleCreationAction;
import org.jboss.loom.actions.XsltAction;
import org.jboss.loom.conf.Configuration;
import org.jboss.loom.ex.MigrationException;
import org.jboss.loom.migrators._ext.ActionDefs;
import org.jboss.loom.migrators._ext.ActionDefs.CliActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.CopyActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.ManualActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.ModuleActionDef;
import org.jboss.loom.migrators._ext.ActionDefs.XsltActionDef;
import org.jboss.loom.migrators._ext.ContainerOfStackableDefs;
import org.jboss.loom.migrators._ext.DefinitionBasedMigrator;
import org.jboss.loom.migrators._ext.MigratorDefinition;
import org.jboss.loom.spi.IConfigFragment;
import org.jboss.loom.utils.el.IExprLangEvaluator;
import org.jboss.loom.utils.el.IExprLangEvaluator.JuelCustomResolverEvaluator;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;

/**
 *  Processor for migrator definitions from .mig.xml files.
 *  These define:
 * 
 *    * JAXB classes, coded as Groovy files.
 *    * Queries which result in a list of IConfigFragment (typically, backed by those JAXB classes).
 *    * ForEach iterators which iterate over results of queries.
 *      * ForEach's define a variable which is available in EL and sub-contexts.
 * 
 *    * Nested elements which result in actions.
{'fraction_non_alphanumeric': 0.10250990752972258, 'fraction_numerical': 0.0010568031704095112, 'mean_word_length': 5.268211920529802, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 2}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3755017', 'n_tokens_mistral': 1351, 'n_tokens_neox': 1307, 'n_words': 233}