move #traverseInheritance to StreamUtils