Hi Roy,
this sounds like something I did before, the way I read it, you have some view of your entity available (such as the input view of a wrapper action or something) and as part of what you log, you also want to retrieve the metadata of whatever entity your wrapper is for, without explicitly having to hardcode the entity name.
So if that's the case (you have some view, input/local/whatever available of your targeted entity), my solution might work for you.
See attached oml. It might be slow, so probably not to be used in bulk/critical situations.
So what I'm doing is take any objectified entity view, turn it into xml, and search for the entity name in the xml.
Dorine