Broke out the file pattern parser ready for integration