if (classes.isEmpty())
return;
String props = Configurations.getProperties(action);
action = Configurations.getClassName(action);
MappingTool tool = new MappingTool(conf, action, false);
Configurations.configureInstance(tool, conf, props,
"SynchronizeMappings");
// initialize the schema
Class cls;
for (Iterator itr = classes.iterator(); itr.hasNext();) {
cls = (Class) itr.next();
try {
tool.run(cls);
} catch (IllegalArgumentException iae) {
throw new UserException(_loc.get("bad-synch-mappings",
action, Arrays.asList(MappingTool.ACTIONS)));
}
}
tool.record();
}