allow the use of a path-to-class dict (O(1)) instead of constant regex searching (O(n))