fix error on non unique class name completion in xml, yaml and twig #387 and refactoring for use same provider