if(yamlStreamReader == null) {
throw new SmooksException("The InputSource doesn't provide a Reader character stream. Make sure that you supply a reader to the Smooks.filterSource method.");
}
YamlToSaxHandler yamlToSaxHandler = new YamlToSaxHandler(contentHandler, anchorAttributeName, aliasAttributeName, indent);
EventHandler eventHandler;
if(aliasStrategy == AliasStrategy.REFER) {
eventHandler = new AliasReferencingEventHandler(yamlToSaxHandler);
} else {
eventHandler = new AliasResolvingEventHandler(yamlEventStreamParser, yamlToSaxHandler, aliasStrategy == AliasStrategy.REFER_RESOLVE);
}