Get Model Document Path via API

I want to get the string via API that is listed in the component properties under "Model Document Path".

Is there some API command for that or do I need to build up that string myself?

I.e.

- for nonvirtual components, I want to get the file path (which can be gotten via IModelDoc2.GetPathName() or IComponent2.GetPathName()).

- for virtual components, I want to get the name of the component, followed by an @, followed by the name of its parent component.

SolidworksApi/macros