Fix file retreiving when using artifact in the reactor

If we add an artifact  as dependency which is used in the reactor, then a null pointer exception is thrown.
It's due to the fact that artifact file is not a jar but target/classes path.
Similar to https://jira.codehaus.org/browse/MDEP-187 https://jira.codehaus.org/browse/MDEP-98