if (line.length() == 0)
continue;
String[] tokens = StringTools.split(line, ':');
if (tokens.length != 3)
throw new FFMQException("Invalid template mapping line : "+line,"INVALID_TEMPLATE_MAPPING");
boolean isQueueTemplate = tokens[0].equalsIgnoreCase("queue");
String destinationNamePattern = tokens[1];
String templateName = tokens[2];
if (isQueueTemplate)
addQueueTemplateMapping(new TemplateMapping(destinationNamePattern,templateName));
else
addTopicTemplateMapping(new TemplateMapping(destinationNamePattern,templateName));
}
input.close();
}
catch (IOException e)
{
throw new FFMQException("Cannot read templates mapping file","FS_ERROR",e);
}
}