refactored MetadataParser, but i'm not fine with that design