support for multiple selector_names and many general refactorings