title: How to get all transitive dependencies programatically
body: <p>I have seen many posts on this, but let me say that i am not trying to write a plugin.
  I am making a project analyser which needs to find out resolved dependencies with their path.</p>
  
  <p>Given a pom.xml(in a project) i want to find out all the dependencies(transitive too) with their paths and if possible the missing dependencies too.</p>
  
  <p>Getting a version independent solution would be bonus.</p>
  
  <p>PS: Every answer is suggesting to use exec to run the command on cli, i am already using this and want to find a better approach of doing this.</p>